summaryrefslogtreecommitdiffstats
path: root/cpukit/libnetworking
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2006-08-30 13:18:40 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2006-08-30 13:18:40 +0000
commit48b1e29a7dc74c6cb1d3e33103b8c09e63c10015 (patch)
treec580b022418af39de9ff70c2ad2c578014f94a15 /cpukit/libnetworking
parent2006-08-29 Joel Sherrill <joel@OARcorp.com> (diff)
downloadrtems-48b1e29a7dc74c6cb1d3e33103b8c09e63c10015.tar.bz2
2006-08-30 Joel Sherrill <joel@OARcorp.com>
* libcsupport/src/utsname.c, libnetworking/libc/res_debug.c, libnetworking/net/if_media.h, libnetworking/rtems/rtems_mii_ioctl.c, librpc/src/rpc/svc_simple.c: Remove printf format warnings.
Diffstat (limited to 'cpukit/libnetworking')
-rw-r--r--cpukit/libnetworking/libc/res_debug.c4
-rw-r--r--cpukit/libnetworking/net/if_media.h2
-rw-r--r--cpukit/libnetworking/rtems/rtems_mii_ioctl.c5
3 files changed, 7 insertions, 4 deletions
diff --git a/cpukit/libnetworking/libc/res_debug.c b/cpukit/libnetworking/libc/res_debug.c
index 19fb9180c8..8d41fa818d 100644
--- a/cpukit/libnetworking/libc/res_debug.c
+++ b/cpukit/libnetworking/libc/res_debug.c
@@ -98,6 +98,8 @@ static char sccsid[] = "@(#)res_debug.c 8.1 (Berkeley) 6/4/93";
static char rcsid[] = "$Id$";
#endif /* LIBC_SCCS and not lint */
+#include <inttypes.h>
+
#include <sys/types.h>
#include <sys/param.h>
#include <sys/socket.h>
@@ -532,7 +534,7 @@ p_time(u_int32_t value) {
static char nbuf[40];
if (ns_format_ttl(value, nbuf, sizeof nbuf) < 0)
- sprintf(nbuf, "%u", value);
+ sprintf(nbuf, "%" PRIu32, value);
return (nbuf);
}
diff --git a/cpukit/libnetworking/net/if_media.h b/cpukit/libnetworking/net/if_media.h
index e52c89c021..6d7f14b713 100644
--- a/cpukit/libnetworking/net/if_media.h
+++ b/cpukit/libnetworking/net/if_media.h
@@ -272,7 +272,7 @@ int ifmedia_ioctl(struct ifnet *ifp, struct ifreq *ifr,
* Macro to create a media word.
*/
#define IFM_MAKEWORD(type, subtype, options, instance) \
- ((type) | (subtype) | (options) | ((instance) << IFM_ISHIFT))
+ ((type) | (subtype) | (options) | ((uint32_t)(instance) << IFM_ISHIFT))
#define IFM_MAKEMODE(mode) \
(((mode) << IFM_MSHIFT) & IFM_MMASK)
diff --git a/cpukit/libnetworking/rtems/rtems_mii_ioctl.c b/cpukit/libnetworking/rtems/rtems_mii_ioctl.c
index 5ee8186f05..fa6261459a 100644
--- a/cpukit/libnetworking/rtems/rtems_mii_ioctl.c
+++ b/cpukit/libnetworking/rtems/rtems_mii_ioctl.c
@@ -11,6 +11,7 @@
/* Author: Till Straumann, <straumanatslacdotstandorddotedu>, 2005 */
#include <rtems.h>
+#include <inttypes.h>
#undef _KERNEL
#undef KERNEL
@@ -61,8 +62,8 @@ rtems_ifmedia2str (int media, char *buf, int bufsz)
dupdesc = IFM_FDX & media ? " full-duplex" : " half-duplex";
return WHATPRINT (buf, bufsz,
- "Ethernet [phy instance: %i]: (link %s, autoneg %s) -- media: %s%s",
- IFM_INST (media),
+ "Ethernet [phy instance: %" PRId32 "]: (link %s, autoneg %s) -- media: %s%s",
+ (int32_t) IFM_INST (media),
IFM_LINK_OK & media ? "ok" : "down",
IFM_ANEG_DIS & media ? "off" : "on",
mdesc, dupdesc ? dupdesc : "");