]> granicus.if.org Git - python/commitdiff
Merge: #18399: fix comment typo.
authorR David Murray <rdmurray@bitdance.com>
Wed, 10 Jul 2013 15:57:39 +0000 (11:57 -0400)
committerR David Murray <rdmurray@bitdance.com>
Wed, 10 Jul 2013 15:57:39 +0000 (11:57 -0400)
1  2 
Modules/python.c

index 0ad1130f1991b848b3695e81d8070665707a5a52,8a548d3ac33d18ead077e0c88e62e74f72aa027f..71335deb5abebce98412b225c0ac1c372a26381f
@@@ -18,19 -18,11 +18,19 @@@ wmain(int argc, wchar_t **argv
  int
  main(int argc, char **argv)
  {
 -    wchar_t **argv_copy = (wchar_t **)PyMem_Malloc(sizeof(wchar_t*)*(argc+1));
 +    wchar_t **argv_copy;
-     /* We need a second copies, as Python might modify the first one. */
+     /* We need a second copy, as Python might modify the first one. */
 -    wchar_t **argv_copy2 = (wchar_t **)PyMem_Malloc(sizeof(wchar_t*)*(argc+1));
 +    wchar_t **argv_copy2;
      int i, res;
      char *oldloc;
 +
 +    argv_copy = (wchar_t **)PyMem_RawMalloc(sizeof(wchar_t*) * (argc+1));
 +    argv_copy2 = (wchar_t **)PyMem_RawMalloc(sizeof(wchar_t*) * (argc+1));
 +    if (!argv_copy || !argv_copy2) {
 +        fprintf(stderr, "out of memory\n");
 +        return 1;
 +    }
 +
      /* 754 requires that FP exceptions run in "no stop" mode by default,
       * and until C vendors implement C99's ways to control FP exceptions,
       * Python requires non-stop mode.  Alas, some platforms enable FP