diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2021-06-08 16:10:19 +0200 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2021-06-08 16:10:19 +0200 |
commit | b139d20c0e599ac394db0f70d563263d6fbb68d3 (patch) | |
tree | da5167740ddaed9472e47925426fee4c3b0a54cd /src | |
parent | ff383ef1a8ab732269621a50fa4f42a4974872ce (diff) | |
parent | 0294977b5458ee2c0ba77b6b2b94fb4a4d6a1310 (diff) | |
download | libpam-freerdp2-master.tar.gz libpam-freerdp2-master.tar.bz2 libpam-freerdp2-master.zip |
Attributes GH PR #2: https://github.com/ArcticaProject/libpam-freerdp2/pull/2
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.am | 1 | ||||
-rw-r--r-- | src/freerdp2-auth-check.c | 10 | ||||
-rw-r--r-- | src/pam-freerdp2.c | 8 |
3 files changed, 10 insertions, 9 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 581b080..ab3deed 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -44,6 +44,7 @@ freerdp2_auth_check_SOURCES = \ $(NULL) freerdp2_auth_check_CFLAGS = \ + -Wall -Werror \ $(FREERDP2_CFLAGS) \ $(WINPR2_CFLAGS) \ $(COVERAGE_CFLAGS) \ diff --git a/src/freerdp2-auth-check.c b/src/freerdp2-auth-check.c index 04558fb..ab3b1fd 100644 --- a/src/freerdp2-auth-check.c +++ b/src/freerdp2-auth-check.c @@ -24,31 +24,31 @@ BOOL -auth_context_new (freerdp * instance, rdpContext * context) +auth_context_new (freerdp __attribute__((unused)) *instance, rdpContext __attribute__((unused)) *context) { return TRUE; } void -auth_context_free (freerdp * instance, rdpContext * context) +auth_context_free (freerdp __attribute__((unused)) *instance, rdpContext __attribute__((unused)) *context) { return; } BOOL -auth_pre_connect (freerdp * instance) +auth_pre_connect (freerdp __attribute__((unused)) *instance) { return TRUE; } BOOL -auth_post_connect (freerdp * instance) +auth_post_connect (freerdp __attribute__((unused)) *instance) { return TRUE; } int -main (int argc, char * argv[]) +main (int argc, char *argv[]) { char password[512]; if (argc != 4) { diff --git a/src/pam-freerdp2.c b/src/pam-freerdp2.c index 18a4c18..593dde5 100644 --- a/src/pam-freerdp2.c +++ b/src/pam-freerdp2.c @@ -240,7 +240,7 @@ get_item (pam_handle_t * pamh, int type) /* Authenticate. We need to make sure we have a user account, that there are remote accounts and then verify them with FreeRDP */ PAM_EXTERN int -pam_sm_authenticate (pam_handle_t *pamh, int flags, int argc, const char **argv) +pam_sm_authenticate (pam_handle_t *pamh, int __attribute__((unused)) flags, int __attribute__((unused)) argc, const char __attribute__((unused)) **argv) { char * username = NULL; char * password = NULL; @@ -305,7 +305,7 @@ pid_t session_pid = 0; give the credentials to the session itself so that it can startup the xfreerdp viewer for the login */ PAM_EXTERN int -pam_sm_open_session (pam_handle_t *pamh, int flags, int argc, const char ** argv) +pam_sm_open_session (pam_handle_t *pamh, int __attribute__((unused)) flags, int __attribute__((unused)) argc, const char __attribute__((unused)) **argv) { char * username = NULL; char * password = NULL; @@ -372,7 +372,7 @@ done: /* Close Session. Make sure our little guy has died so he doesn't become a zombie and eat things. */ PAM_EXTERN int -pam_sm_close_session (pam_handle_t *pamh, int flags, int argc, const char **argv) +pam_sm_close_session (pam_handle_t *pamh, int __attribute__((unused)) flags, int __attribute__((unused)) argc, const char __attribute__((unused)) **argv) { if (session_pid == 0) { return PAM_IGNORE; @@ -452,7 +452,7 @@ unpriveleged_kill (struct passwd * pwdent) /* LightDM likes to have this function around, but we don't need it as we don't have a token hanging around. */ PAM_EXTERN int -pam_sm_setcred (pam_handle_t *pamh, int flags, int argc, const char ** argv) +pam_sm_setcred (pam_handle_t __attribute__((unused)) *pamh, int __attribute__((unused)) flags, int __attribute__((unused)) argc, const char __attribute__((unused)) **argv) { return PAM_SUCCESS; } |