summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2017-03-28 16:16:01 +0300
committerPanu Matilainen <pmatilai@redhat.com>2017-03-28 16:34:12 +0300
commit2652bab3e900c2b6b393a480d34a8c6b772cc113 (patch)
tree30facd85c52208986a588f103de490e056eb1131
parentf30d96772e2954ec0ca3b2a81097ec98c2a50751 (diff)
downloadrpm-2652bab3e900c2b6b393a480d34a8c6b772cc113.tar.gz
Eliminate rpmdsNotify() from the API + Python bindings
This is an internal helper for debug logging and should've never been part of the API in the first place. We're removing all sorts of things on this round anyway so it's a fine opportunity for removing this too. It's not as if anybody used this outside rpm because it's ... not exactly useful.
-rw-r--r--lib/rpmds.h9
-rw-r--r--lib/rpmds_internal.h9
-rw-r--r--python/rpmds-py.c17
3 files changed, 9 insertions, 26 deletions
diff --git a/lib/rpmds.h b/lib/rpmds.h
index a113609ae..19a94982e 100644
--- a/lib/rpmds.h
+++ b/lib/rpmds.h
@@ -314,15 +314,6 @@ rpm_color_t rpmdsColor(const rpmds ds);
rpm_color_t rpmdsSetColor(const rpmds ds, rpm_color_t color);
/** \ingroup rpmds
- * Notify of results of dependency match.
- * @param ds dependency set
- * @param where where dependency was resolved (or NULL)
- * @param rc 0 == YES, otherwise NO
- */
-/* FIX: rpmMessage annotation is a lie */
-void rpmdsNotify(rpmds ds, const char * where, int rc);
-
-/** \ingroup rpmds
* Return next dependency set iterator index.
* @param ds dependency set
* @return dependency set iterator index, -1 on termination
diff --git a/lib/rpmds_internal.h b/lib/rpmds_internal.h
index 86d449871..6861fba0f 100644
--- a/lib/rpmds_internal.h
+++ b/lib/rpmds_internal.h
@@ -22,6 +22,15 @@ int rpmdsMatches(rpmstrPool pool, Header h, int prix,
rpmds req, int selfevr, int nopromote);
/** \ingroup rpmds
+ * Notify of results of dependency match.
+ * @param ds dependency set
+ * @param where where dependency was resolved (or NULL)
+ * @param rc 0 == YES, otherwise NO
+ */
+RPM_GNUC_INTERNAL
+void rpmdsNotify(rpmds ds, const char * where, int rc);
+
+/** \ingroup rpmds
* Return current dependency name pool id.
* @param ds dependency set
* @return current dependency name id, 0 on invalid
diff --git a/python/rpmds-py.c b/python/rpmds-py.c
index d51573176..9eae9a228 100644
--- a/python/rpmds-py.c
+++ b/python/rpmds-py.c
@@ -97,21 +97,6 @@ rpmds_SetNoPromote(rpmdsObject * s, PyObject * args, PyObject * kwds)
return Py_BuildValue("i", rpmdsSetNoPromote(s->ds, nopromote));
}
-static PyObject *
-rpmds_Notify(rpmdsObject * s, PyObject * args, PyObject * kwds)
-{
- const char * where;
- int rc;
- char * kwlist[] = {"location", "returnCode", NULL};
-
- if (!PyArg_ParseTupleAndKeywords(args, kwds, "si:Notify", kwlist,
- &where, &rc))
- return NULL;
-
- rpmdsNotify(s->ds, where, rc);
- Py_RETURN_NONE;
-}
-
/* XXX rpmdsFind uses bsearch on s->ds, so a sort is needed. */
static PyObject *
rpmds_Sort(rpmdsObject * s)
@@ -207,8 +192,6 @@ static struct PyMethodDef rpmds_methods[] = {
{"SetNoPromote",(PyCFunction)rpmds_SetNoPromote, METH_VARARGS|METH_KEYWORDS,
"ds.SetNoPromote(noPromote) -- Set noPromote for this instance.\n\n"
"If True non existing epochs are no longer equal to an epoch of 0."},
- {"Notify", (PyCFunction)rpmds_Notify, METH_VARARGS|METH_KEYWORDS,
- "ds.Notify(location, returnCode) -- Print debug info message\n\n if debugging is enabled."},
{"Sort", (PyCFunction)rpmds_Sort, METH_NOARGS,
NULL},
{"Find", (PyCFunction)rpmds_Find, METH_O,