mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-08-21 22:04:56 -06:00
uppsrc: Visual C++ compiler bug [W]StringBuffer workaround
git-svn-id: svn://ultimatepp.org/upp/trunk@15123 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
313a4b1d90
commit
9293ed2be0
41 changed files with 99 additions and 99 deletions
|
|
@ -10,7 +10,7 @@ String MakeSqlValue(int code, T& value)
|
|||
StringBuffer b(sizeof(T) + 1);
|
||||
b[0] = code;
|
||||
memcpy(~b + 1, &value, sizeof(T));
|
||||
return b;
|
||||
return String(b);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
|
|
@ -327,7 +327,7 @@ String SqlCompile(byte dialect, const String& s)
|
|||
b.Reserve(s.GetLength() + 100);
|
||||
const char *q = s;
|
||||
SqlCompile(q, &b, dialect, NULL);
|
||||
return b;
|
||||
return String(b);
|
||||
}
|
||||
|
||||
#ifndef NOAPPSQL
|
||||
|
|
@ -370,7 +370,7 @@ String SqlFormat0(const char *s, int l, int code)
|
|||
b[0] = code;
|
||||
memcpy(~b + 1, &l, sizeof(int));
|
||||
memcpy(~b + 1 + sizeof(int), s, l);
|
||||
return b;
|
||||
return String(b);
|
||||
}
|
||||
|
||||
String SqlFormat(const char *s, int l)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue