Skip to content

Commit

Permalink
Concatenate TEXT constants rather than TEXT concatenated constants
Browse files Browse the repository at this point in the history
TEXT("foo" "bar") => L"foo" "bar" => error concatenating wide string and ascii string
TEXT("foo") TEXT("bar") => L"foo" L"bar" => compile OK
  • Loading branch information
nicolas-cellier-aka-nice committed Dec 27, 2018
1 parent 28cf9c6 commit 9e82899
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -306,7 +306,7 @@ sqInt ioShowDisplayOnWindow(unsigned char* dispBits, sqInt width,

if(lines == 0) {
printLastError(TEXT("SetDIBitsToDevice failed"));
warnPrintf(TEXT("width=%" PRIdSQINT ",height=%" PRIdSQINT ",bits=%" PRIXSQPTR ",dc=%" PRIXSQPTR "\n"),
warnPrintf(TEXT("width=%") TEXT(PRIdSQINT) TEXT(",height=%") TEXT(PRIdSQINT) TEXT(",bits=%") TEXT(PRIXSQPTR) TEXT(",dc=%") TEXT(PRIXSQPTR) TEXT("\n"),
width, height, (usqIntptr_t)dispBits, (usqIntptr_t)dc);
}
/* reverse the image bits if necessary */
Expand Down
2 changes: 1 addition & 1 deletion platforms/win32/vm/sqWin32Window.c
Expand Up @@ -2587,7 +2587,7 @@ sqInt ioShowDisplay(sqInt dispBits, sqInt width, sqInt height, sqInt depth,

if(lines == 0) {
printLastError(TEXT("SetDIBitsToDevice failed"));
warnPrintf(TEXT("width=%" PRIdSQINT ",height=%" PRIdSQINT ",bits=%" PRIXSQINT ",dc=%" PRIXSQPTR "\n"),
warnPrintf(TEXT("width=%") TEXT(PRIdSQINT) TEXT(",height=%") TEXT(PRIdSQINT) TEXT(",bits=%") TEXT(PRIXSQINT) TEXT(",dc=%") TEXT(PRIXSQPTR) TEXT("\n"),
width, height, dispBits,(usqIntptr_t)dc);
}
/* reverse the image bits if necessary */
Expand Down

0 comments on commit 9e82899

Please sign in to comment.