Loïc Bartoletti 3587128a97 libgis: close files if G_copy_file fails (#2266) 3 年之前
..
colors b8ae3bb419 Replace CRLF by LF in color table, test, license (#2147) 3 年之前
tests 941b533cad libgis: Add function to read or read again GISRC var (#2244) 3 年之前
testsuite fdff46c1a3 r.slope.aspect: implement parallelization with OpenMP (#1767) 3 年之前
FIPS.code db49180dd7 welcome to GRASS 7.0.svn 17 年之前
G.h 0ae0be6386 Enable zlib compression by default (set GRASS_INT_ZLIB=0 to use RLE) 10 年之前
Makefile 35d350051d add ZSTD (Zstandard) compression to the Make system 7 年之前
README.TYPE d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
adj_cellhd.c a1c9c22da0 g.region: Add more detail into LL error messages (#1988) 3 年之前
alloc.c 48b4f09d9d fix copyright initial year (from G6) 12 年之前
aprintf.c cbc5b386da More clear comments (#726) 4 年之前
area.c 36233b8479 libgis: minor doxygen header updates 10 年之前
area_ellipse.c 36233b8479 libgis: minor doxygen header updates 10 年之前
area_poly1.c 5cf0f4c431 libgis: stabilize G_ellipsoid_polygon_area() 7 年之前
area_poly2.c 36233b8479 libgis: minor doxygen header updates 10 年之前
area_sphere.c 36233b8479 libgis: minor doxygen header updates 10 年之前
ascii_chk.c 36233b8479 libgis: minor doxygen header updates 10 年之前
asprintf.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
basename.c a8382f8cff libgis: fix https://trac.osgeo.org/grass/changeset/73981 6 年之前
bres_line.c 36233b8479 libgis: minor doxygen header updates 10 年之前
clicker.c c313e28597 Bundle static variables into per-file structures 16 年之前
cmprbzip.c 1ca54bb823 libgis: more informative messages when (de)compression fails 7 年之前
cmprlz4.c 1ca54bb823 libgis: more informative messages when (de)compression fails 7 年之前
cmprrle.c 70f29a0a3d libgis: add ZSTD (Zstandard) compression 7 年之前
cmprzlib.c 1ca54bb823 libgis: more informative messages when (de)compression fails 7 年之前
cmprzstd.c 1ca54bb823 libgis: more informative messages when (de)compression fails 7 年之前
color_rules.c f3d15d7228 libgis: +G_color_rules_description_type(), +G_list_color_rules_description_type() 6 年之前
color_str.c 963a888573 libgis: set copyright year to latest change 8 年之前
colors.desc bac9d79240 color table percentage forest cover (#894) 4 年之前
commas.c 36233b8479 libgis: minor doxygen header updates 10 年之前
compress.c 67ecc48337 libgis: add warnings when writing compressed data fails 7 年之前
compress.h dca9364c64 configure: upgrade to autoconf 2.69 (#1845) 3 年之前
copy_dir.c 2209cfeb1c libgis: doxygenize copy_dir.c 10 年之前
copy_file.c 3587128a97 libgis: close files if G_copy_file fails (#2266) 3 年之前
counter.c aff756a341 Fix G_is_initialized() for case of concurrent initialisation attempts 16 年之前
date.c 36233b8479 libgis: minor doxygen header updates 10 年之前
datum.c 1a84429e14 some fixes for 'error: format not a string literal and no format arguments [-Werror=format-security]' 11 年之前
datum.table 20de9db8d9 datum.table: add RGFG95 (#813) 4 年之前
datumtransform.table 2a013c1ed3 datum: add support for D_Rauenberg_1983 (#1331) 4 年之前
debug.c cc77b8dc34 libgis: G__getenv() -> G_getenv_nofatal() 10 年之前
distance.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
done_msg.c 36233b8479 libgis: minor doxygen header updates 10 年之前
ellipse.table db49180dd7 welcome to GRASS 7.0.svn 17 年之前
ellipse.table.solar.system 6d61c04a2f removed tainted ellipsoids 11 年之前
endian.c 36233b8479 libgis: minor doxygen header updates 10 年之前
env.c 941b533cad libgis: Add function to read or read again GISRC var (#2244) 3 年之前
error.c 9b61d2e668 libgis: use G_vasprintf() to avoid buffer overflow 7 年之前
file_name.c 7e30d84ed8 Improve G_open|find _misc function documentation (#1760) 3 年之前
find_etc.c 09b7db1dd9 doxygen errors fixed 12 年之前
find_file.c 7e30d84ed8 Improve G_open|find _misc function documentation (#1760) 3 年之前
find_rast.c 36233b8479 libgis: minor doxygen header updates 10 年之前
find_rast3d.c dc7822aafa G_find_grid3 moved from raster3d to gislib 13 年之前
find_vect.c 36233b8479 libgis: minor doxygen header updates 10 年之前
fmode.c 1acdd0be01 Build system clean-up 16 年之前
geodesic.c c7041e9ca3 Remove unnecessary return values 16 年之前
geodist.c 36233b8479 libgis: minor doxygen header updates 10 年之前
get_ellipse.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
get_projinfo.c 515095365a r.out.gdal / v.out.ogr: fix xy export (#1564) 4 年之前
get_window.c b80f665b3a libgis: catch empty region file (suggested in https://lists.osgeo.org/pipermail/grass-dev/2015-August/075933.html) 9 年之前
getl.c 36233b8479 libgis: minor doxygen header updates 10 年之前
gis_local_proto.h cca863b4cf libgis: merge local_proto.h with gis_local_proto.h 10 年之前
gisbase.c bc702cc96b major gislib.dox update (still not complete) 16 年之前
gisdbase.c 36233b8479 libgis: minor doxygen header updates 10 年之前
gisinit.c f062bffc82 GIS_H_VERSION: use git hash (#325) 5 年之前
gislib.dox 7d9a0da4fc manuals and docs: update broken URLS (#1003) 4 年之前
gislib_cmdline_parsing.dox 443635d275 Happy New Year (#2059) 3 年之前
handler.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
home.c cca863b4cf libgis: merge local_proto.h with gis_local_proto.h 10 年之前
ilist.c 5120adf63f Fixed potential memory leak in integer list init, added new and free ilist functions. 11 年之前
intersect.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
is.c 36233b8479 libgis: minor doxygen header updates 10 年之前
key_value1.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
key_value2.c 745e71030a libgis: doxygen docs update (key_value_[1|2|3].c) 13 年之前
key_value3.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
key_value4.c 36233b8479 libgis: minor doxygen header updates 10 年之前
legal_name.c f5f03b13e1 G_legal_filename: Update a warning message to be more correct 10 年之前
line_dist.c c7041e9ca3 Remove unnecessary return values 16 年之前
list.c f852a88bdc libgis: G__ls -> G_ls2 10 年之前
ll_format.c 08bf434bd7 libgis: do not wrap to -180,180 8 年之前
ll_scan.c 7855552114 libgis: relax ll restrictions when reading DMS coords 8 年之前
locale.c c37871b51d Fix -Wunused-variable compiler warnings (#2158) 3 年之前
location.c 1f879e823a libgis: use HOST_DIRSEP in filenames (see https://trac.osgeo.org/grass/changeset/65639) 9 年之前
lrand48.c 38765847ba Allow to use a fixed random seed via SOURCE_DATE_EPOCH (#251) 5 年之前
ls.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
ls_filter.c 36233b8479 libgis: minor doxygen header updates 10 年之前
lz4.c 158a6f2a5a bulk fixing of typos in comments (using tools/fix_typos.sh) 6 年之前
lz4.h 897fea9ac4 Fix spelling errors. (#2053) 3 年之前
mach_name.c 474402cb81 Various MinGW bugfixes from Rosen Matev 16 年之前
make_loc.c 2bb77ed6a4 Fix uninitialized, scope, leak, const issues in C (#2250) 3 年之前
make_mapset.c 3255999f82 libgis: LOCATION -> LOCATION_NAME in G_make_mapset(), fixes https://trac.osgeo.org/grass/ticket/2040 6 年之前
mapcase.c 09b7db1dd9 doxygen errors fixed 12 年之前
mapset.c cc77b8dc34 libgis: G__getenv() -> G_getenv_nofatal() 10 年之前
mapset_msc.c e9fe9ac783 libgis: add missing return keyword (#1751) 3 年之前
mapset_nme.c a3791a8ca6 Lib: Speed up listing a lot of mapsets by 20%. (#281) 5 年之前
mkstemp.c 74fb4e5301 Add parentheses to avoid warning 11 年之前
myname.c 36233b8479 libgis: minor doxygen header updates 10 年之前
named_colr.c 671e44225a Fix formatting of array initialisers 16 年之前
new_des db49180dd7 welcome to GRASS 7.0.svn 17 年之前
nl_to_spaces.c 8868d4b686 indent -bad -bap -bbb -br -bli0 -bls -cli0 -ncs -fc1 -hnl -i4 \ 16 年之前
nme_in_mps.c a5f20635d6 G_unqualified_name: Correct the usage 10 年之前
open.c 23a8e6d786 libgis: Distinguish dirs and objects in dir creation (#1681) 3 年之前
open_misc.c 7e30d84ed8 Improve G_open|find _misc function documentation (#1760) 3 年之前
overwrite.c cc77b8dc34 libgis: G__getenv() -> G_getenv_nofatal() 10 年之前
pager.c dca9364c64 configure: upgrade to autoconf 2.69 (#1845) 3 年之前
parser.c 27b12e21a0 parser: Show error for option file (#1433) 4 年之前
parser_dependencies.c d2dd0dd262 Add angle brackets to a single option/flag rule (#1399) 4 年之前
parser_help.c d8d5cc7113 parser: do not show empty flags section 5 年之前
parser_html.c a7a7817670 manual: improved HTML page headers (#946) 4 年之前
parser_interface.c 84fa33ffa8 Add inter-dependency rules to --interface-description output 10 年之前
parser_json.c c37871b51d Fix -Wunused-variable compiler warnings (#2158) 3 年之前
parser_local_proto.h c646680beb Added actinia JSON compatible output to the GRASS parser for any module 6 年之前
parser_rest.c ad0e965e75 manual: put module name at first position (#248) 5 年之前
parser_script.c 635224115c parser: Use #-space-% to allow writing PEP8-compliant Python code (#1287) 4 年之前
parser_standard_options.c f12f145790 parser: Add NPROCS GIS env var to set default for nprocs (#1734) 3 年之前
parser_wps.c 15d6526eac GRASS GIS 8 dev: version bump to grass81 (#2084) 3 年之前
paths.c 623c7b94ec simplify wingrass LFS 11 年之前
percent.c 291b94a5be G_progress() does not support GRASS_MESSAGE_FORMAT=gui, fixes https://trac.osgeo.org/grass/ticket/2751 6 年之前
pi.h db49180dd7 welcome to GRASS 7.0.svn 17 年之前
plot.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
pole_in_poly.c 36233b8479 libgis: minor doxygen header updates 10 年之前
popen.c 770e798241 G_spawn_ex() expects descriptors as "int"s, not "char*". 15 年之前
progrm_nme.c f820d866f5 parser: provide wxGUI forms.py with a full path if available (https://trac.osgeo.org/grass/ticket/2133) 9 年之前
proj1.c 3fc17c1072 remove unused PROJECTION_SP 10 年之前
proj2.c 501ec6aa98 -int G__projection_units(int); 10 年之前
proj3.c c6e81b98e8 Fix spelling in comments, esp. in wxGUI code (#1357) 4 年之前
projections c7478c69d3 enable Geostationary Satellite View (merge from devbr6) 15 年之前
put_window.c cca863b4cf libgis: merge local_proto.h with gis_local_proto.h 10 年之前
putenv.c 5c454c7ad2 gislib: cosmetics in doxygen documentation 13 年之前
radii.c 36233b8479 libgis: minor doxygen header updates 10 年之前
rd_cellhd.c bcd7779fe8 libgis, G__read_Cell_head_array(): more informative error messages (fix https://trac.osgeo.org/grass/changeset/40698) 8 年之前
remove.c a1dfd3cf37 make GRASS data TMPDIR configurable (GRASS_TMPDIR_MAPSET && TMPDIR) 10 年之前
rename.c a1dfd3cf37 make GRASS data TMPDIR configurable (GRASS_TMPDIR_MAPSET && TMPDIR) 10 年之前
renamed_options e56c9cad17 Renamed options/flags update for temporal modules 8 年之前
rhumbline.c 36233b8479 libgis: minor doxygen header updates 10 年之前
rotate.c 36233b8479 libgis: minor doxygen header updates 10 年之前
seek.c f6b0f3aad4 libgis: report reason if unable to seek 6 年之前
set_window.c cca863b4cf libgis: merge local_proto.h with gis_local_proto.h 10 年之前
short_way.c 36233b8479 libgis: minor doxygen header updates 10 年之前
sleep.c 8868d4b686 indent -bad -bap -bbb -br -bli0 -bls -cli0 -ncs -fc1 -hnl -i4 \ 16 年之前
snprintf.c 36233b8479 libgis: minor doxygen header updates 10 年之前
spawn.c 03d5e48411 Fix cast from pointer to int of different size (#1405) 4 年之前
state27 db49180dd7 welcome to GRASS 7.0.svn 17 年之前
state83 db49180dd7 welcome to GRASS 7.0.svn 17 年之前
strings.c 62f0ccf0af libgis: add string concatenation function (#1401) 4 年之前
tempfile.c 23a8e6d786 libgis: Distinguish dirs and objects in dir creation (#1681) 3 年之前
timestamp.c 6f71886c6e libgis: G__write_timestamp() -> G_write_timestamp() 10 年之前
token.c d33152f1d5 Numerous typos fixed (identified with tools/fix_typos.sh) 8 年之前
trim_dec.c 36233b8479 libgis: minor doxygen header updates 10 年之前
units.c 36233b8479 libgis: minor doxygen header updates 10 年之前
user_config.c 36233b8479 libgis: minor doxygen header updates 10 年之前
verbose.c 2b56d2452d Various typos (fixes https://trac.osgeo.org/grass/ticket/2882 Patch for various spelling errors (sebastic)) 9 年之前
view.c 36233b8479 libgis: minor doxygen header updates 10 年之前
whoami.c 36233b8479 libgis: minor doxygen header updates 10 年之前
win32_pipes.c 8868d4b686 indent -bad -bap -bbb -br -bli0 -bls -cli0 -ncs -fc1 -hnl -i4 \ 16 年之前
wind_2_box.c 36233b8479 libgis: minor doxygen header updates 10 年之前
wind_format.c 36233b8479 libgis: minor doxygen header updates 10 年之前
wind_in.c 36233b8479 libgis: minor doxygen header updates 10 年之前
wind_limits.c 36233b8479 libgis: minor doxygen header updates 10 年之前
wind_overlap.c 12b23b92e2 libgis, G_window_percentage_overlap(): account for N == S or E == W 8 年之前
wind_scan.c 389f087644 libgis: always check if res > 0 8 年之前
window_map.c ee01a8edf4 libgis: fix G_adjust_east_longitude() and G_adjust_easting() 8 年之前
worker.c 3500fb0a88 Set default workers to zero (threads only used by explicit request) 9 年之前
wr_cellhd.c 36233b8479 libgis: minor doxygen header updates 10 年之前
writ_zeros.c 36233b8479 libgis: minor doxygen header updates 10 年之前
xdr.c 36233b8479 libgis: minor doxygen header updates 10 年之前
zero.c 36233b8479 libgis: minor doxygen header updates 10 年之前
zone.c 36233b8479 libgis: minor doxygen header updates 10 年之前

README.TYPE

.\" use -ms
.LP
There were two flavors of changes made to structures in gis.h
and to calls to routines in the library:

.IP 1.
Variables in structures, parameters in argument lists to library routines,
and return values from library routines that really represented
CELL data but were declared as int have been changed to CELL.

The following structures were changed:

.DS
Categories [gis.h]
Cell_stats
Colors
Histogram
Range
Reclass
.DE

The argument type for some parameters for the following routines was changed:

.DS
G_init_cats [cats.c]
G_get_cats
G_set_cats
G_get_color [color.c]
G_set_color
G_make_random_colors [make_colr2.c]
G_make_color_wave
G_make_grey_scale
G_make_color_ramp
G_make_aspect_colors
G_add_histogram [histogram.c]
G_set_histogram
G_update_range [range.c]
.DE

The return value for the following routines was changed:

.DS
G_number_of_cats [cats.c]
G_get_histogram_cat [histogram.c]
.DE

This change does not, at present, require changes to existing code since
the CELL type is currently defined as int.

In the future, if we (or someone else) want to
redefine CELL to long (say on a 16 bit machine), the application code
will compile ok, but will not run correctly since the calling seqences
(including printf and scanf) will not match anymore.
To upgrade GRASS code for this is a big deal.
It consists of
finding all places that ints are used in assignments with
CELL variables,
modifying all the calls to the above routines,
and modifying all calls to other routines that don't know about the CELL
type (in particular printf, scanf, and Vask code).

The way to handle printf for CELL data is to use %ld and cast the
CELL value to long:
.DS
CELL x
printf ("%ld", (long) x);
.DE
The way to handle scanf for CELL data is to use %ld into a long
and assign to the CELL variable:
.DS
CELL x;
long t;

scanf ("%ld", &t);
x = (CELL) t;
.DE
For Vask calls, assign the CELL value to a long, call Vask will the long,
then assign the long to the CELL variable:
.DS
CELL x;
long t;

t = x;
V_clear();
V_ques (&t, 'l', ...);
V_call();
x = t;
.DE

The long vs int issue for CELL also presents a subtle, but
potentially fatal, problem with malloc(n) which requires n to be int.

Suppose we want to allocate an array for reclass, from
cats min to max. What we do now is

.DS
char *table;
CELL min,max;
int len;

len = max - min + 1;
table = malloc (len);
.DE
This will fail if CELL is long and the expression max-min+1 yields
a value which overflows an int. Therefore, we should do
.DS
long len;

len = max - min + 1;
if (len != (int)len)
error("Too many categories");
table = malloc ((int)len);
.DE
.IP 2.
Variables in structures, parameters in argument lists to library routines,
and return values from library routines that should have been long
but were declared as int have been changed to long.

The following structures were changed:

.DS
Cell_stats [gis.h]
Histogram
.DE

The argument type for some parameters for the following routines was changed:

.DS
G_add_histogram [histogram.c]
G_set_histogram
G_find_cell_stat [cell_stats.c]
G_next_cell_stat
.DE

The return value for the following routines was changed:

.DS
G_get_histogram_count [histogram.c]
.DE


These changes required immediate upgrade.
I think this update is done, but I want to review it again.