| 2249 | } |
| 2250 | |
| 2251 | static inline PyObject* |
| 2252 | PySys_GetAttr(PyObject *name) |
| 2253 | { |
| 2254 | #if PY_VERSION_HEX >= 0x03000000 |
| 2255 | const char *name_str = PyUnicode_AsUTF8(name); |
| 2256 | #else |
| 2257 | const char *name_str = PyString_AsString(name); |
| 2258 | #endif |
| 2259 | if (name_str == NULL) { |
| 2260 | return NULL; |
| 2261 | } |
| 2262 | |
| 2263 | return PySys_GetAttrString(name_str); |
| 2264 | } |
| 2265 | |
| 2266 | static inline int |
| 2267 | PySys_GetOptionalAttrString(const char *name, PyObject **value) |
nothing calls this directly
no test coverage detected