1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-31 16:57:10 +00:00

This commit was generated by cvs2svn to compensate for changes in r93526,

which included commits to RCS files with non-trunk default branches.
This commit is contained in:
Dag-Erling Smørgrav 2002-04-01 12:20:48 +00:00
commit 0f3ac1c96f
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=93527

View File

@ -31,7 +31,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $P4: //depot/projects/openpam/lib/pam_set_data.c#8 $
* $P4: //depot/projects/openpam/lib/pam_set_data.c#9 $
*/
#include <stdlib.h>
@ -74,11 +74,13 @@ pam_set_data(pam_handle_t *pamh,
if ((dp = malloc(sizeof *dp)) == NULL)
return (PAM_BUF_ERR);
if ((dp->name = strdup(module_data_name)) == NULL) {
free(data);
free(dp);
return (PAM_BUF_ERR);
}
dp->data = data;
dp->cleanup = cleanup;
dp->next = pamh->module_data;
pamh->module_data = data;
pamh->module_data = dp;
return (PAM_SUCCESS);
}