rlutil icon indicating copy to clipboard operation
rlutil copied to clipboard

fix error when UNICODE defined

Open TheKrush opened this issue 7 years ago • 6 comments

Code doesn't currently compile if UNICODE is defined, this fixes that

TheKrush avatar Aug 10 '16 19:08 TheKrush

Hello Windows my old friend...

sigh :+1:

nabijaczleweli avatar Aug 10 '16 23:08 nabijaczleweli

a better choice (i think):

#ifdef UNICODE
		WriteConsoleOutputCharacterA(hConsoleOutput, str, len, csbi.dwCursorPosition, &numberOfCharsWritten);
#else // UNICODE
		WriteConsoleOutputCharacter(hConsoleOutput, str, len, csbi.dwCursorPosition, &numberOfCharsWritten);
#endif // UNICODE

ardi69 avatar Jan 06 '17 09:01 ardi69

@TheKrush can you amend your commit based on @ardi69 suggestion? Merely add #ifdef UNICODE :)

hashar avatar Nov 28 '17 23:11 hashar

There is also #48

hashar avatar Nov 28 '17 23:11 hashar

Done.

TheKrush avatar Nov 29 '17 00:11 TheKrush

There is no reason to use #ifdef UNICODE, because when UNICODE isn't defined, WriteConsoleOutputCharacter simply calls WriteConsoleOutputCharacterA.

MangaD avatar Aug 13 '19 23:08 MangaD