mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Squashed compiler warnings by adding casts, making sure prototypes are in
scope and looking at types.
This commit is contained in:
parent
446f32367b
commit
0a116f3a29
4 changed files with 7 additions and 3 deletions
|
@ -421,7 +421,7 @@ calculate_path(void)
|
||||||
*/
|
*/
|
||||||
pythonModule = NSModuleForSymbol(NSLookupAndBindSymbol("_Py_Initialize"));
|
pythonModule = NSModuleForSymbol(NSLookupAndBindSymbol("_Py_Initialize"));
|
||||||
/* Use dylib functions to find out where the framework was loaded from */
|
/* Use dylib functions to find out where the framework was loaded from */
|
||||||
buf = NSLibraryNameForModule(pythonModule);
|
buf = (char *)NSLibraryNameForModule(pythonModule);
|
||||||
if (buf != NULL) {
|
if (buf != NULL) {
|
||||||
/* We're in a framework. */
|
/* We're in a framework. */
|
||||||
/* See if we might be in the build directory. The framework in the
|
/* See if we might be in the build directory. The framework in the
|
||||||
|
|
|
@ -13,6 +13,10 @@ extern PyObject* pyvms_gr_empty_string;
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(WITH_NEXT_FRAMEWORK)
|
||||||
|
#include "pymactoolbox.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
#if (defined(PYOS_OS2) && !defined(PYCC_GCC)) || defined(MS_WINDOWS)
|
#if (defined(PYOS_OS2) && !defined(PYCC_GCC)) || defined(MS_WINDOWS)
|
||||||
#define PYTHONHOMEHELP "<prefix>\\lib"
|
#define PYTHONHOMEHELP "<prefix>\\lib"
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -77,7 +77,7 @@ dl_funcptr _PyImport_GetDynLoadFunc(const char *fqname, const char *shortname,
|
||||||
newModule = NSLinkModule(image, pathname, LINKOPTIONS);
|
newModule = NSLinkModule(image, pathname, LINKOPTIONS);
|
||||||
if (newModule == NULL) {
|
if (newModule == NULL) {
|
||||||
int errNo;
|
int errNo;
|
||||||
char *fileName, *moreErrorStr;
|
const char *fileName, *moreErrorStr;
|
||||||
NSLinkEditErrors c;
|
NSLinkEditErrors c;
|
||||||
NSLinkEditError( &c, &errNo, &fileName, &moreErrorStr );
|
NSLinkEditError( &c, &errNo, &fileName, &moreErrorStr );
|
||||||
PyOS_snprintf(errBuf, 512, "Failure linking new module: %s: %s",
|
PyOS_snprintf(errBuf, 512, "Failure linking new module: %s: %s",
|
||||||
|
|
|
@ -53,7 +53,7 @@ char *PyMac_getscript()
|
||||||
/* This leaks a an object. */
|
/* This leaks a an object. */
|
||||||
name = CFStringConvertEncodingToIANACharSetName(enc);
|
name = CFStringConvertEncodingToIANACharSetName(enc);
|
||||||
}
|
}
|
||||||
return CFStringGetCStringPtr(name, 0);
|
return (char *)CFStringGetCStringPtr(name, 0);
|
||||||
#else
|
#else
|
||||||
int font, script, lang;
|
int font, script, lang;
|
||||||
font = 0;
|
font = 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue