util_errors.h revision 1319e71fd1680ca4864afe0b1aca2b8c8e4a1ee4
ecd6aa105c55994db06993bab3c967247656bacbStephen Gallagher Copyright (C) 2012 Red Hat
b6840554b4eeda395f5460a56df2eac1f3f97397Lukas Slebodnik This program is free software; you can redistribute it and/or modify
b6840554b4eeda395f5460a56df2eac1f3f97397Lukas Slebodnik it under the terms of the GNU General Public License as published by
b6840554b4eeda395f5460a56df2eac1f3f97397Lukas Slebodnik the Free Software Foundation; either version 3 of the License, or
b6840554b4eeda395f5460a56df2eac1f3f97397Lukas Slebodnik (at your option) any later version.
1f7573f8c74ff0f488a15969caed13034a95bd0fStephen Gallagher This program is distributed in the hope that it will be useful,
1f7573f8c74ff0f488a15969caed13034a95bd0fStephen Gallagher but WITHOUT ANY WARRANTY; without even the implied warranty of
b6840554b4eeda395f5460a56df2eac1f3f97397Lukas Slebodnik MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
bfbf5cb0f00c60c0f000f56c282377b13b9a89abSumit Bose GNU General Public License for more details.
4eafef4572f4e5ff6b589c80db0b9417724f229fJan Cholasta You should have received a copy of the GNU General Public License
4eafef4572f4e5ff6b589c80db0b9417724f229fJan Cholasta along with this program. If not, see <http://www.gnu.org/licenses/>.
4eafef4572f4e5ff6b589c80db0b9417724f229fJan Cholasta Simo Sorce <ssorce@redhat.com>
0b52717b76bf306afd30bbeb6d6c619365cfb548Stephen Gallagher * We define a specific number space so that we do not overlap with other
0b52717b76bf306afd30bbeb6d6c619365cfb548Stephen Gallagher * generic errors returned by various libraries. This will make it easy
0b52717b76bf306afd30bbeb6d6c619365cfb548Stephen Gallagher * to have functions that double check that what was returned was a SSSD
2344d7f71dd80618a41745b0818b46895fa61b2cLukas Slebodnik * specific error where it matters. For example we may want to ensure some
12a73062d84fec27536b09fd275ea248d14b93e5Jakub Hrozek * particularly sensitive paths only return SSSD sepcific errors as that
12a73062d84fec27536b09fd275ea248d14b93e5Jakub Hrozek * will insure all error conditions have been explicitly dealt with,
12a73062d84fec27536b09fd275ea248d14b93e5Jakub Hrozek * and are not the result of assigning the wrong return result.
c3b1e99007d5f0069fbbd32a3df799d71ea4882eSumit Bose * Basic system errno errors can still be used, but when an error condition
c3b1e99007d5f0069fbbd32a3df799d71ea4882eSumit Bose * does not properly map to a system error we should use a SSSD specific one
8a5e793a0576250da80371e53aa3e7eba15cdb63Sumit Bose/* never use ERR_INVALID, it is used for catching and returning