forked from OSGeo/gdal
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing a recently added error about the umber of bytes to be copyied
- Loading branch information
Showing
1 changed file
with
1 addition
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2410,7 +2410,7 @@ int MM_SecureCopyStringFieldValue(char **pszStringDst, const char *pszStringSrc, | |
|
||
// We just copy the exact number of elements we want to copy. | ||
// If we copy more than them, some garbage can appear in the record | ||
memcpy(*pszStringDst, pszStringSrc, *nStringCurrentLength); | ||
memcpy(*pszStringDst, pszStringSrc, strlen(pszStringSrc)); | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
AbelPau
Author
Owner
|
||
return 0; | ||
} | ||
|
||
|
what about the nul terminating byte? Shouldn't that be strlen(pszStringSrc) + 1 ?