~ubuntu-branches/ubuntu/saucy/sssd/saucy

« back to all changes in this revision

Viewing changes to sss_client/sss_pam_macros.h

  • Committer: Stéphane Graber
  • Date: 2011-06-15 16:23:14 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: stgraber@ubuntu.com-20110615162314-rbhoppnpaxfqo5q7
Merge 1.5.8

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * System Security Services Daemon. Client Interface for NSS and PAM.
3
 
 *
4
 
 * Copyright (C) Stephen Gallagher 2009
5
 
 *
6
 
 * You can used this header file in any way you see fit provided copyright
7
 
 * notices are preserved.
8
 
 *
9
 
 */
10
 
 
11
 
#ifndef _SSS_PAM_MACROS_H
12
 
#define _SSS_PAM_MACROS_H
13
 
 
14
 
/* Older versions of the pam development headers do not include the
15
 
 * _pam_overwrite_n(n,x) macro. This implementation is copied from
16
 
 * the Fedora 11 _pam_macros.h.
17
 
 */
18
 
#include <security/_pam_macros.h>
19
 
#ifndef _pam_overwrite_n
20
 
#define _pam_overwrite_n(x,n)   \
21
 
do {                             \
22
 
     register char *__xx__;      \
23
 
     register unsigned int __i__ = 0;    \
24
 
     if ((__xx__=(x)))           \
25
 
        for (;__i__<n; __i__++) \
26
 
            __xx__[__i__] = 0; \
27
 
} while (0)
28
 
#endif /* _pam_overwrite_n */
29
 
 
30
 
#endif /* _SSS_PAM_MACROS_H */