MCPcopy Create free account
hub / github.com/cruppstahl/upscaledb / env_open

Function env_open

python/src/python.cc:188–211  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

186}
187
188static PyObject *
189env_open(UpsEnvironment *self, PyObject *args)
190{
191 ups_status_t st;
192 const char *filename = 0;
193 uint32_t flags = 0;
194 PyObject *extargs = 0;
195 std::vector<ups_parameter_t> params;
196
197 if (!PyArg_ParseTuple(args, "|ziO!:open", &filename, &flags,
198 &PyTuple_Type, &extargs))
199 return (0);
200
201 if (extargs) {
202 if (!parse_parameters(extargs, params))
203 return (0);
204 }
205
206 st = ups_env_open(&self->env, filename, flags, extargs ? &params[0] : 0);
207 if (st)
208 THROW(st);
209
210 return (Py_BuildValue(""));
211}
212
213static PyObject *
214env_close(UpsEnvironment *self, PyObject *args)

Callers

nothing calls this directly

Calls 1

parse_parametersFunction · 0.85

Tested by

no test coverage detected