aboutsummaryrefslogtreecommitdiff
path: root/src/pj_malloc.c
diff options
context:
space:
mode:
authorFrank Warmerdam <warmerdam@pobox.com>2011-02-08 23:22:01 +0000
committerFrank Warmerdam <warmerdam@pobox.com>2011-02-08 23:22:01 +0000
commit98ea774575d9a21f7a9d975c2aa67fdb548458e2 (patch)
tree30d1c913646da536cff8183ae4c1a11c36242710 /src/pj_malloc.c
parent4294bc272cf563b7897c2dfae7a583c7cc45f1e1 (diff)
downloadPROJ-98ea774575d9a21f7a9d975c2aa67fdb548458e2.tar.gz
PROJ-98ea774575d9a21f7a9d975c2aa67fdb548458e2.zip
avoid cplusplus comments (#92)
git-svn-id: http://svn.osgeo.org/metacrs/proj/trunk@1965 4e78687f-474d-0410-85f9-8d5e500ac6b2
Diffstat (limited to 'src/pj_malloc.c')
-rw-r--r--src/pj_malloc.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/pj_malloc.c b/src/pj_malloc.c
index b6400eba..80443a2b 100644
--- a/src/pj_malloc.c
+++ b/src/pj_malloc.c
@@ -7,12 +7,14 @@
void *
pj_malloc(size_t size) {
-// Currently, pj_malloc is a hack to solve an errno problem.
-// The problem is described in more details at
-// https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=86420.
-// It seems, that pj_init and similar functions incorrectly
-// (under debian/glibs-2.3.2) assume that pj_malloc resets
-// errno after success. pj_malloc tries to mimic this.
+/*
+/ Currently, pj_malloc is a hack to solve an errno problem.
+/ The problem is described in more details at
+/ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=86420.
+/ It seems, that pj_init and similar functions incorrectly
+/ (under debian/glibs-2.3.2) assume that pj_malloc resets
+/ errno after success. pj_malloc tries to mimic this.
+*/
int old_errno = errno;
void *res = malloc(size);
if ( res && !old_errno )