replaced buffer copy and strcmp() with strncmp() (patch 632155)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@17713 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -925,10 +925,7 @@ int wxEntry( int argc, char *argv[] , bool enterLoop )
|
||||
// application (otherwise applications would need to handle it)
|
||||
|
||||
if (argc > 1) {
|
||||
char theArg[6] = "";
|
||||
strncpy(theArg, argv[1], 5);
|
||||
|
||||
if (strcmp(theArg, "-psn_") == 0) {
|
||||
if (strncmp(argv[1], "-psn_", 5) == 0) {
|
||||
// assume the argument is always the only one and remove it
|
||||
--argc;
|
||||
}
|
||||
|
@@ -925,10 +925,7 @@ int wxEntry( int argc, char *argv[] , bool enterLoop )
|
||||
// application (otherwise applications would need to handle it)
|
||||
|
||||
if (argc > 1) {
|
||||
char theArg[6] = "";
|
||||
strncpy(theArg, argv[1], 5);
|
||||
|
||||
if (strcmp(theArg, "-psn_") == 0) {
|
||||
if (strncmp(argv[1], "-psn_", 5) == 0) {
|
||||
// assume the argument is always the only one and remove it
|
||||
--argc;
|
||||
}
|
||||
|
Reference in New Issue
Block a user