Commit 9da79623 authored by Samuel Debionne's avatar Samuel Debionne

Makes the _xlat_date buff bigger to handle longer path

parent e4214963
......@@ -132,6 +132,7 @@ time_t getTimestamp() { return time(NULL); }
//$Id: [Oct 8 2013 15:21:07] [Tue Oct 8 15:21:07 2013] (..\..\..\..\src\PcoCamera.cpp) $
#define LEN_BUFF_DATE 128
#define LEN_BUFF_PATH 260 //Same as MAX_PATH under Windows
#define TOKNR_DT 5
......@@ -171,9 +172,9 @@ int __xlat_date(char *s1, char &ptrTo, int lenTo) {
}
char *_xlat_date(char *s1, char *s2, char *s3) {
static char buff[LEN_BUFF_DATE+1];
static char buff[2 * LEN_BUFF_DATE + LEN_BUFF_PATH];
char *ptr = buff;
char *ptrMax = buff + LEN_BUFF_DATE;
char *ptrMax = buff + sizeof(buff) - 1;
ptr += sprintf_s(ptr, ptrMax - ptr, "$Id: comp[");
ptr += __xlat_date(s1, *ptr, (int) (ptrMax - ptr));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment