Created
February 28, 2014 14:55
-
-
Save zhenghao1/9272518 to your computer and use it in GitHub Desktop.
User defined functions cannot return local variables
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void getID(DWORD mask, TCHAR* item) | |
{ | |
_stprintf(item, "Hello World!"); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TCHAR* getID(DWORD mask) | |
{ | |
TCHAR item[20]; | |
_stprintf(item, "Hello World!"); | |
return item; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment