summaryrefslogtreecommitdiff
path: root/src/geo.h
diff options
context:
space:
mode:
authorantirez <antirez@gmail.com>2015-06-25 18:05:45 +0200
committerantirez <antirez@gmail.com>2015-06-26 10:58:27 +0200
commitfa9d62d34fd739160b2a45b713e912a6c4dabb75 (patch)
tree20e15aa95be84c04239de9610a1d4b42740ba190 /src/geo.h
parent03ce18962848fdd1b7a8427a7365096a0c7b3d4f (diff)
downloadredis-fa9d62d34fd739160b2a45b713e912a6c4dabb75.tar.gz
Geo: from lat,lon API to lon,lat API according to GIS standard
The GIS standard and all the major DBs implementing GIS related functions take coordinates as x,y that is longitude,latitude. It was a bad start for Redis to do things differently, so even if this means that existing users of the Geo module will be required to change their code, Redis now conforms to the standard. Usually Redis is very backward compatible, but this is not an exception to this rule, since this is the first Geo implementation entering the official Redis source code. It is not wise to try to be backward compatible with code forks... :-) Close #2637.
Diffstat (limited to 'src/geo.h')
-rw-r--r--src/geo.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/geo.h b/src/geo.h
index 9cd1f56b4..4f5c5e6fe 100644
--- a/src/geo.h
+++ b/src/geo.h
@@ -12,8 +12,8 @@ void geoAddCommand(redisClient *c);
/* Structures used inside geo.c in order to represent points and array of
* points on the earth. */
typedef struct geoPoint {
- double latitude;
double longitude;
+ double latitude;
double dist;
double score;
char *member;