]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/app.cpp
Tweaked the layout sample a bit for wxGridBagSizer
[wxWidgets.git] / src / mac / app.cpp
index a8ca3cdb669a24720efbe41514235b953acb7a9d..baa2127bbfb32725e30fba4c1135a6a8b57d3eb2 100644 (file)
@@ -609,10 +609,11 @@ bool wxApp::Initialize(int& argc, wxChar **argv)
     if ( argc > 1 )
     {
         static const wxChar *ARG_PSN = _T("-psn_");
     if ( argc > 1 )
     {
         static const wxChar *ARG_PSN = _T("-psn_");
-        if ( wxStrncmp(argv[1], ARG_PSN, sizeof(ARG_PSN) - 1) == 0 )
+        if ( wxStrncmp(argv[1], ARG_PSN, wxStrlen(ARG_PSN)) == 0 )
         {
             // remove this argument
         {
             // remove this argument
-            memmove(argv, argv + 1, argc--);
+            --argc;
+            memmove(argv + 1, argv + 2, argc * sizeof(char *));
         }
     }
 
         }
     }