summaryrefslogtreecommitdiff
path: root/libshouldbeinlibc
diff options
context:
space:
mode:
authorFlavio Cruz <flaviocruz@gmail.com>2015-12-29 22:48:16 +0100
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2015-12-29 23:03:26 +0100
commitadeeb9990e6302482b38267fd517a2516d5b9e2a (patch)
treec1c91df6046a229f0195665368431c7b12996efc /libshouldbeinlibc
parent4c0d8ebb6494af95f125e1e829dfb7453b7ad03e (diff)
fix compiler warnings in hurd/libshouldbeinlibc
Diffstat (limited to 'libshouldbeinlibc')
-rw-r--r--libshouldbeinlibc/portinfo.c8
-rw-r--r--libshouldbeinlibc/ugids-verify-auth.c5
-rw-r--r--libshouldbeinlibc/xportinfo.c2
3 files changed, 8 insertions, 7 deletions
diff --git a/libshouldbeinlibc/portinfo.c b/libshouldbeinlibc/portinfo.c
index e6305c6e..f3c540f5 100644
--- a/libshouldbeinlibc/portinfo.c
+++ b/libshouldbeinlibc/portinfo.c
@@ -53,7 +53,7 @@ print_port_info (mach_port_t name, mach_port_type_t type, task_t task,
return err;
}
- fprintf (stream, hex_names ? "%#6zx: " : "%6zd: ", name);
+ fprintf (stream, hex_names ? "%#6lx: " : "%6lu: ", name);
if (type & MACH_PORT_TYPE_RECEIVE)
{
@@ -68,7 +68,7 @@ print_port_info (mach_port_t name, mach_port_type_t type, task_t task,
fprintf (stream, " (");
if (status.mps_pset != MACH_PORT_NULL)
fprintf (stream,
- hex_names ? "port-set: %#zx, " : "port-set: %zd, ",
+ hex_names ? "port-set: %#lx, " : "port-set: %lu, ",
status.mps_pset);
fprintf (stream, "seqno: %zu", status.mps_seqno);
if (status.mps_mscount)
@@ -119,9 +119,9 @@ print_port_info (mach_port_t name, mach_port_type_t type, task_t task,
fprintf (stream, " (empty)");
else
{
- fprintf (stream, hex_names ? " (%#zx" : " (%zu", members[0]);
+ fprintf (stream, hex_names ? " (%#lx" : " (%lu", members[0]);
for (i = 1; i < members_len; i++)
- fprintf (stream, hex_names ? ", %#zx" : ", %zu",
+ fprintf (stream, hex_names ? ", %#lx" : ", %lu",
members[i]);
fprintf (stream, ")");
munmap ((caddr_t) members, members_len * sizeof *members);
diff --git a/libshouldbeinlibc/ugids-verify-auth.c b/libshouldbeinlibc/ugids-verify-auth.c
index 0e85b1b6..f6991aa2 100644
--- a/libshouldbeinlibc/ugids-verify-auth.c
+++ b/libshouldbeinlibc/ugids-verify-auth.c
@@ -65,9 +65,10 @@ server_verify_make_auth (const char *password,
{
auth_t auth;
struct svma_state *svma_state = hook;
- error_t (*check) (io_t server, uid_t id, const char *passwd, auth_t *auth) =
+ /* Mig routines don't use 'const' for passwd. */
+ error_t (*check) (io_t server, uid_t id, char *passwd, auth_t *auth) =
is_group ? password_check_group : password_check_user;
- error_t err = (*check) (svma_state->server, id, password, &auth);
+ error_t err = (*check) (svma_state->server, id, (char *) password, &auth);
if (! err)
/* PASSWORD checked out ok; the corresponding authentication is in AUTH. */
diff --git a/libshouldbeinlibc/xportinfo.c b/libshouldbeinlibc/xportinfo.c
index cce6fb6c..47e6dd9a 100644
--- a/libshouldbeinlibc/xportinfo.c
+++ b/libshouldbeinlibc/xportinfo.c
@@ -35,7 +35,7 @@ print_xlated_port_info (mach_port_t name, mach_port_type_t type,
error_t err = port_name_xlator_xlate (x, name, type, &name, &type);
if (! err)
{
- fprintf (stream, (show & PORTINFO_HEX_NAMES) ? "%#6zx => " : "%6zd => ",
+ fprintf (stream, (show & PORTINFO_HEX_NAMES) ? "%#6lx => " : "%6lu => ",
old_name);
err = print_port_info (name, type, x->to_task, show, stream);
}