Created
October 1, 2015 13:14
-
-
Save tskenb/9ca5d50a680149d7d1c8 to your computer and use it in GitHub Desktop.
Don't remove trailing spaces
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
diff --git a/src/tds_fdw.c b/src/tds_fdw.c | |
index 7976c3b..64b6a0c 100644 | |
--- a/src/tds_fdw.c | |
+++ b/src/tds_fdw.c | |
@@ -989,7 +989,7 @@ char* tdsConvertToCString(DBPROCESS* dbproc, int srctype, const BYTE* src, DBINT | |
case SYBVARCHAR: | |
case SYBTEXT: | |
real_destlen = srclen + 1; /* the size of the array */ | |
- destlen = -1; /* the size to pass to dbconvert (-1 means to null terminate it) */ | |
+ destlen = -2; /* the size to pass to dbconvert (-2 means to null terminate it) */ | |
desttype = SYBCHAR; | |
break; | |
case SYBBINARY: | |
@@ -1068,7 +1068,7 @@ char* tdsConvertToCString(DBPROCESS* dbproc, int srctype, const BYTE* src, DBINT | |
default: | |
real_destlen = 1000; /* Probably big enough */ | |
- destlen = -1; | |
+ destlen = -2; | |
desttype = SYBCHAR; | |
break; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment