Skip to content

Commit

Permalink
librpc/py_security: exception message blames the bad SID
Browse files Browse the repository at this point in the history
It can be useful to know what you're looking for.

Signed-off-by: Douglas Bagnall <[email protected]>
Reviewed-by: Andrew Bartlett <[email protected]>
  • Loading branch information
douglasbagnall authored and abartlet committed Apr 28, 2023
1 parent aa378b4 commit 489cdc4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion source4/librpc/ndr/py_security.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ static int py_dom_sid_init(PyObject *self, PyObject *args, PyObject *kwargs)
return -1;

if (str != NULL && !dom_sid_parse(str, sid)) {
PyErr_SetString(PyExc_ValueError, "Unable to parse string");
PyErr_Format(PyExc_ValueError,
"Unable to parse string: '%s'", str);
return -1;
}

Expand Down

0 comments on commit 489cdc4

Please sign in to comment.