Staging
v0.5.1
https://github.com/python/cpython
Revision 069b8d20be8018fbd49ed5aaf64c4caba311e48f authored by Antoine Pitrou on 11 March 2018, 19:09:20 UTC, committed by GitHub on 11 March 2018, 19:09:20 UTC
In some conditions the standard streams will be None or closed in the child process (for example if using "pythonw" instead of "python" on Windows).  Avoid failing with a non-0 exit code in those conditions.

Report and initial patch by poxthegreat..
(cherry picked from commit e756f66c83786ee82f5f7d45931ae50a6931dd7f)
1 parent 20ac11a
Raw File
Tip revision: 069b8d20be8018fbd49ed5aaf64c4caba311e48f authored by Antoine Pitrou on 11 March 2018, 19:09:20 UTC
[3.6] bpo-31804: Fix multiprocessing.Process with broken standard streams (GH-6079) (GH-6081)
Tip revision: 069b8d2
strdup.c
/* strdup() replacement (from stdwin, if you must know) */

#include "pgenheaders.h"

char *
strdup(const char *str)
{
	if (str != NULL) {
		char *copy = malloc(strlen(str) + 1);
		if (copy != NULL)
			return strcpy(copy, str);
	}
	return NULL;
}
back to top