From 874f75e8f4fdf1cc18b1bba7a0d97d8043d3377d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dag-Erling=20Sm=C3=B8rgrav?= Date: Sat, 22 Oct 2011 01:03:23 +0000 Subject: [PATCH] Document that the item argument (for pam_get_item(3)) and the data argument (for pam_get_data(3)) are untouched if the function fails. git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@444 185d5e19-27fe-0310-9dcf-9bff6b9f3609 --- lib/pam_get_data.c | 1 + lib/pam_get_item.c | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/pam_get_data.c b/lib/pam_get_data.c index 21ace5a..ae947a5 100644 --- a/lib/pam_get_data.c +++ b/lib/pam_get_data.c @@ -84,6 +84,7 @@ pam_get_data(const pam_handle_t *pamh, * context specified by the =pamh argument. * A pointer to the object is stored in the location pointed to by the * =data argument. + * If =pam_get_data fails, the =data argument is untouched. * * This function and its counterpart =pam_set_data are useful for managing * data that are meaningful only to a particular service module. diff --git a/lib/pam_get_item.c b/lib/pam_get_item.c index 7ee71b9..939e29c 100644 --- a/lib/pam_get_item.c +++ b/lib/pam_get_item.c @@ -108,10 +108,12 @@ pam_get_item(const pam_handle_t *pamh, /** * The =pam_get_item function stores a pointer to the item specified by - * the =item_type argument in the location specified by the =item + * the =item_type argument in the location pointed to by the =item * argument. * The item is retrieved from the PAM context specified by the =pamh * argument. + * If =pam_get_item fails, the =item argument is untouched. + * * The following item types are recognized: * * =PAM_SERVICE: