aboutsummaryrefslogtreecommitdiff
path: root/sysutils/policykit/files/patch-tools_polkit-auth.c
diff options
context:
space:
mode:
authorJoe Marcus Clarke <marcus@FreeBSD.org>2008-03-24 03:52:36 +0000
committerJoe Marcus Clarke <marcus@FreeBSD.org>2008-03-24 03:52:36 +0000
commit6f32add9a75efb180e462ffbdb0b080bc88088e3 (patch)
tree0fc7af36e22fc0dc7c1dc8aacabf6fe117e881da /sysutils/policykit/files/patch-tools_polkit-auth.c
parentb8d245fedd5842fb6d68d0bdc6539885555a84e3 (diff)
downloadports-6f32add9a75efb180e462ffbdb0b080bc88088e3.tar.gz
ports-6f32add9a75efb180e462ffbdb0b080bc88088e3.zip
Notes
Diffstat (limited to 'sysutils/policykit/files/patch-tools_polkit-auth.c')
-rw-r--r--sysutils/policykit/files/patch-tools_polkit-auth.c61
1 files changed, 61 insertions, 0 deletions
diff --git a/sysutils/policykit/files/patch-tools_polkit-auth.c b/sysutils/policykit/files/patch-tools_polkit-auth.c
new file mode 100644
index 000000000000..f3ee42d1f55d
--- /dev/null
+++ b/sysutils/policykit/files/patch-tools_polkit-auth.c
@@ -0,0 +1,61 @@
+--- tools/polkit-auth.c.orig 2007-12-05 22:30:18.000000000 -0500
++++ tools/polkit-auth.c 2007-12-23 01:43:36.000000000 -0500
+@@ -37,12 +37,13 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <sys/wait.h>
+ #include <pwd.h>
+ #include <grp.h>
+ #include <unistd.h>
+ #include <errno.h>
+ #include <termios.h>
+
+ #include <polkit-dbus/polkit-dbus.h>
+ #include <polkit-grant/polkit-grant.h>
+
+@@ -107,7 +109,7 @@ conversation_select_admin_user (PolKitGr
+ }
+ printf ("\n");
+ printf ("Select user: ");
+- getline (&lineptr, &linelen, stdin);
++ polkit_sysdeps_getline (&lineptr, &linelen, stdin);
+ user = strdup (lineptr);
+ free (lineptr);
+ return user;
+@@ -133,7 +135,7 @@ conversation_pam_prompt_echo_off (PolKit
+ exit (1);
+ }
+
+- getline (&lineptr, &linelen, stdin);
++ polkit_sysdeps_getline (&lineptr, &linelen, stdin);
+
+ /* Restore terminal. */
+ tcsetattr (fileno (stdout), TCSAFLUSH, &old);
+@@ -151,7 +153,7 @@ conversation_pam_prompt_echo_on (PolKitG
+ size_t linelen = 0;
+ char *result;
+ printf ("%s", request);
+- getline (&lineptr, &linelen, stdin);
++ polkit_sysdeps_getline (&lineptr, &linelen, stdin);
+ result = strdup (lineptr);
+ free (lineptr);
+ printf ("\n");
+@@ -189,7 +191,7 @@ conversation_override_grant_type (PolKit
+ case POLKIT_RESULT_ONLY_VIA_SELF_AUTH_KEEP_SESSION:
+ printf ("Keep this privilege for the session? [no/session]?\n");
+ again:
+- getline (&lineptr, &linelen, stdin);
++ polkit_sysdeps_getline (&lineptr, &linelen, stdin);
+ if (g_str_has_prefix (lineptr, "no")) {
+ ;
+ } else if (g_str_has_prefix (lineptr, "session")) {
+@@ -204,7 +206,7 @@ conversation_override_grant_type (PolKit
+ case POLKIT_RESULT_ONLY_VIA_SELF_AUTH_KEEP_ALWAYS:
+ printf ("Keep this privilege for the session or always? [no/session/always]?\n");
+ again2:
+- getline (&lineptr, &linelen, stdin);
++ polkit_sysdeps_getline (&lineptr, &linelen, stdin);
+ if (g_str_has_prefix (lineptr, "no")) {
+ ;
+ } else if (g_str_has_prefix (lineptr, "session")) {