Staging
v0.5.1
https://github.com/python/cpython
Revision c2f665e721e4e4629cc4a2c5eb6464c3dc7325e3 authored by Benjamin Peterson on 11 February 2014, 03:19:02 UTC, committed by Benjamin Peterson on 11 February 2014, 03:19:02 UTC
1 parent f0560d9
Raw File
Tip revision: c2f665e721e4e4629cc4a2c5eb6464c3dc7325e3 authored by Benjamin Peterson on 11 February 2014, 03:19:02 UTC
don't put runtime values in array initializer for C89 compliance (closes #20588)
Tip revision: c2f665e
dynload_dl.c

/* Support for dynamic loading of extension modules */

#include "dl.h"

#include "Python.h"
#include "importdl.h"


extern char *Py_GetProgramName(void);

const char *_PyImport_DynLoadFiletab[] = {".o", NULL};


dl_funcptr _PyImport_GetDynLoadFunc(const char *shortname,
                                    const char *pathname, FILE *fp)
{
    char funcname[258];

    PyOS_snprintf(funcname, sizeof(funcname), "PyInit_%.200s", shortname);
    return dl_loadmod(Py_GetProgramName(), pathname, funcname);
}
back to top