AW: Re: [postgis-users] pgsql2shp segfault by multipolygon export

Christian Grau ch.grau at gmx.de
Fri Jul 22 10:18:30 PDT 2005


i apply the patches and the exports now works :-)

i tested the same shapes on a 64bit system with postgresql8.0.2 /
postgis-1.0.2 / suse9.2
there i get the same error message as on the system with postgresql8.0.2 /
postgis-0.9.1 before i applyed the patches

but strange: on a 32bit system with postgresql7.4 / postgis-0.9.1 there is
no problem ?

greetings

christian grau

-----Ursprungliche Nachricht-----
Von: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net]Im Auftrag von
strk at refractions.net
Gesendet: Freitag, 22. Juli 2005 16:33
An: postgis-users at postgis.refractions.net
Betreff: Re: Re: [postgis-users] pgsql2shp segfault by multipolygon
export


Sorry, the following would also be needed.
Previous patch was for GeomFromWKB.
This one is for pgsql2shp

Please let me know if this fixes your problems and we'd be releasing
0.9.2.

--strk;

Index: loader/pgsql2shp.c
===================================================================
RCS file: /home/cvs/postgis/postgis/loader/pgsql2shp.c,v
retrieving revision 1.53.2.4
diff -U2 -r1.53.2.4 pgsql2shp.c
--- loader/pgsql2shp.c  15 Dec 2004 08:53:52 -0000      1.53.2.4
+++ loader/pgsql2shp.c  22 Jul 2005 14:31:49 -0000
@@ -2965,5 +2965,5 @@

 uint32 popint(byte **c) {
-       uint32 i;
+       uint32 i=0;
        memcpy(&i, *c, 4);
        *c+=4;
@@ -2972,5 +2972,5 @@

 uint32 getint(byte *c) {
-       uint32 i;
+       uint32 i=0;
        memcpy(&i, c, 4);
        return i;
@@ -2982,5 +2982,5 @@

 double popdouble(byte **c) {
-       double d;
+       double d=0.0;
        memcpy(&d, *c, 8);
        *c+=8;
_______________________________________________
postgis-users mailing list
postgis-users at postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users




More information about the postgis-users mailing list