00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #include <grass/gis.h>
00016 #include <grass/glocale.h>
00017
00018 int G_put_cellhd (char *name, struct Cell_head *cellhd)
00019 {
00020 FILE *fd ;
00021
00022 if (!(fd = G_fopen_new ("cellhd", name)))
00023 {
00024 char buf[1024];
00025
00026 sprintf (buf, _("Unable to create header file for [%s]"), name);
00027 G_warning (buf);
00028 return -1;
00029 }
00030
00031 G__write_Cell_head (fd, cellhd, 1);
00032 fclose (fd);
00033
00034 return 0;
00035 }