Skip to content

Commit

Permalink
Merge pull request #158 from thbeu/fix-init
Browse files Browse the repository at this point in the history
Nullify userdata also in SASetupUtf8Hooks
  • Loading branch information
rouault authored Aug 21, 2024
2 parents 8e95f3b + 77bd759 commit a42b436
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions safileio.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*
*/

#include "shapefil.h"
#include "shapefil_private.h"

#include <assert.h>
#include <math.h>
Expand Down Expand Up @@ -101,7 +101,7 @@ void SASetupDefaultHooks(SAHooks *psHooks)

psHooks->Error = SADError;
psHooks->Atof = atof;
psHooks->pvUserData = NULL;
psHooks->pvUserData = SHPLIB_NULLPTR;
}

#ifdef SHPAPI_WINDOWS
Expand Down Expand Up @@ -182,5 +182,6 @@ void SASetupUtf8Hooks(SAHooks *psHooks)

psHooks->Error = SADError;
psHooks->Atof = atof;
psHooks->pvUserData = SHPLIB_NULLPTR;
}
#endif

0 comments on commit a42b436

Please sign in to comment.