596 static PyObject *py_sss_groupdel(PySssLocalObject *self,
597 PyObject *args,
598 PyObject *kwds)
599 {
600 struct tools_ctx *tctx = NULL;
601 char *groupname = NULL;
602 int ret;
603
604 if(!PyArg_ParseTuple(args, discard_const_p(char, "s"), &groupname)) {
605 goto fail;
when PyArg_ParseTuple() succeeds
taking False path
606 }
607
608 tctx = init_ctx(self->mem_ctx, self);
609 if (!tctx) {
610 PyErr_NoMemory();
when treating unknown struct tools_ctx * from src/python/pysss.c:609 as non-NULL
taking False path
611 return NULL;
612 }
613
614 tctx->octx->name = groupname;
615
when treating unknown struct ops_ctx * from src/python/pysss.c:615 as non-NULL
616 /* Remove the group */
617 ret = groupdel(tctx, self->sysdb, tctx->octx);
618 if (ret != EOK) {
619 PyErr_SetSssError(ret);
when considering range: -0x80000000 <= value <= -1
taking True path
620 goto fail;
621 }
622
623 talloc_zfree(tctx);
624 Py_RETURN_NONE;
625
626 fail:
627 talloc_zfree(tctx);
628 return NULL;
629 }
630