view Python/getversion.c @ 52475:780d6401eed6 3.0

Issue #5604: non-ASCII characters in module name passed to imp.find_module() were converted to UTF-8 while the path is converted to the default filesystem encoding, causing nonsense. Thanks Andrew Svetlov!
author Guido van Rossum <guido@python.org>
date Mon, 30 Mar 2009 21:43:25 +0000
parents 379fc66f4c96
children 9f2fbee420da
line wrap: on
line source


/* Return the full version string. */

#include "Python.h"

#include "patchlevel.h"

const char *
Py_GetVersion(void)
{
	static char version[250];
	PyOS_snprintf(version, sizeof(version), "%.80s (%.80s) %.80s", 
		      PY_VERSION, Py_GetBuildInfo(), Py_GetCompiler());
	return version;
}