Some more changes to make code compile under a C++ compiler.

This commit is contained in:
Anthony Baxter 2006-04-11 12:14:09 +00:00
parent 7b782b61c5
commit 64182fe0b3
5 changed files with 11 additions and 10 deletions

View file

@ -208,7 +208,7 @@ Py_Main(int argc, char **argv)
/* -c is the last option; following arguments
that look like options are left for the
command to interpret. */
command = malloc(strlen(_PyOS_optarg) + 2);
command = (char *)malloc(strlen(_PyOS_optarg) + 2);
if (command == NULL)
Py_FatalError(
"not enough memory to copy -c argument");
@ -221,7 +221,7 @@ Py_Main(int argc, char **argv)
/* -m is the last option; following arguments
that look like options are left for the
module to interpret. */
module = malloc(strlen(_PyOS_optarg) + 2);
module = (char *)malloc(strlen(_PyOS_optarg) + 2);
if (module == NULL)
Py_FatalError(
"not enough memory to copy -m argument");