summaryrefslogtreecommitdiffstats
path: root/cpukit
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
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')
-rw-r--r--cpukit/ChangeLog6
-rw-r--r--cpukit/libcsupport/src/utsname.c2
-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
-rw-r--r--cpukit/librpc/src/rpc/svc_simple.c4
6 files changed, 17 insertions, 6 deletions
diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog
index 373fc4e1f0..6d4bc7917e 100644
--- a/cpukit/ChangeLog
+++ b/cpukit/ChangeLog
@@ -1,3 +1,9 @@
+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.
+
2006-08-29 Joel Sherrill <joel@OARcorp.com>
* libmisc/capture/capture-cli.c: Remove printf format warnings.
diff --git a/cpukit/libcsupport/src/utsname.c b/cpukit/libcsupport/src/utsname.c
index 6ba6c196c0..d97284b3be 100644
--- a/cpukit/libcsupport/src/utsname.c
+++ b/cpukit/libcsupport/src/utsname.c
@@ -41,7 +41,7 @@ int uname(
strcpy( name->sysname, "RTEMS" );
- sprintf( name->nodename, "Node %" PRId32, _Objects_Local_node );
+ sprintf( name->nodename, "Node %" PRId16, _Objects_Local_node );
strcpy( name->release, RTEMS_VERSION );
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 : "");
diff --git a/cpukit/librpc/src/rpc/svc_simple.c b/cpukit/librpc/src/rpc/svc_simple.c
index 1ad846981a..07dbd10fb5 100644
--- a/cpukit/librpc/src/rpc/svc_simple.c
+++ b/cpukit/librpc/src/rpc/svc_simple.c
@@ -49,6 +49,8 @@ static char *rcsid = "$FreeBSD: src/lib/libc/rpc/svc_simple.c,v 1.9 1999/08/28 0
#include <sys/socket.h>
#include <netdb.h>
+#include <inttypes.h> /* for PRIxx printf formats */
+
struct prog_lst {
char *(*p_progname)();
rpcprog_t p_prognum;
@@ -142,7 +144,7 @@ universal(
return;
if (!svc_sendreply(atransp, lpl->p_outproc, outdata)) {
(void) fprintf(stderr,
- "trouble replying to prog %d\n",
+ "trouble replying to prog %" PRIu32 "\n",
lpl->p_prognum);
exit(1);
}