diff options
author | Sergei Golubchik <sergii@pisem.net> | 2014-08-08 17:58:45 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2014-08-08 17:58:45 +0200 |
commit | 4105cbf4a230c82ea7dee31d4d2262b798fad9f4 (patch) | |
tree | 6a2769940fcaf3fdb520f695b7e954ee29daf245 /storage/connect/filamtxt.cpp | |
parent | 289475896177ff932368810a8b2f2bdbf7e4bcbd (diff) | |
download | mariadb-git-4105cbf4a230c82ea7dee31d4d2262b798fad9f4.tar.gz |
after-merge fixes for 10.0-connectmariadb-10.0.13
Diffstat (limited to 'storage/connect/filamtxt.cpp')
-rw-r--r-- | storage/connect/filamtxt.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/storage/connect/filamtxt.cpp b/storage/connect/filamtxt.cpp index 28059d4f28a..9c0cd51458d 100644 --- a/storage/connect/filamtxt.cpp +++ b/storage/connect/filamtxt.cpp @@ -475,7 +475,7 @@ bool DOSFAM::AllocateBuffer(PGLOBAL g) MODE mode = Tdbp->Mode; // Lrecl does not include line ending - Buflen = Lrecl + Ending + ((Bin) ? 1 : 0); + Buflen = Lrecl + Ending + ((Bin) ? 1 : 0) + 1; if (trace) htrc("SubAllocating a buffer of %d bytes\n", Buflen); @@ -1010,7 +1010,7 @@ bool DOSFAM::MoveIntermediateLines(PGLOBAL g, bool *b) /***********************************************************************/ bool DOSFAM::MakeUpdatedFile(PGLOBAL g) { - char *crlf = "\n", *mode = UseTemp ? "rb" : "r+b"; + const char *crlf = "\n", *mode = UseTemp ? "rb" : "r+b"; int *ix, i; bool moved, b = false; @@ -1084,7 +1084,7 @@ err: /***********************************************************************/ bool DOSFAM::MakeDeletedFile(PGLOBAL g) { - char *crlf = "\n", *mode = UseTemp ? "rb" : "r+b"; + const char *crlf = "\n", *mode = UseTemp ? "rb" : "r+b"; int *ix, i; bool moved; @@ -1535,7 +1535,7 @@ int BLKFAM::WriteBuffer(PGLOBAL g) /*******************************************************************/ /* Mode == MODE_UPDATE. */ /*******************************************************************/ - char *crlf; + const char *crlf; size_t len; int curpos = ftell(Stream); bool moved = true; |