summaryrefslogtreecommitdiffstats
path: root/usr.bin/usbhidaction
diff options
context:
space:
mode:
authorkevlo <kevlo@FreeBSD.org>2010-08-31 07:19:10 +0000
committerkevlo <kevlo@FreeBSD.org>2010-08-31 07:19:10 +0000
commitc7fccca900d4480033c61c12f768a9827d7e7383 (patch)
tree7797c8a9b64d3d6134c74efd195007ed32b81254 /usr.bin/usbhidaction
parentae90c2fd0986f5829f4fdfc1a2137c52f77846cb (diff)
downloadFreeBSD-src-c7fccca900d4480033c61c12f768a9827d7e7383.zip
FreeBSD-src-c7fccca900d4480033c61c12f768a9827d7e7383.tar.gz
For consistency, cast result of getpid() to long
Diffstat (limited to 'usr.bin/usbhidaction')
-rw-r--r--usr.bin/usbhidaction/usbhidaction.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/usbhidaction/usbhidaction.c b/usr.bin/usbhidaction/usbhidaction.c
index fc78d4e..142e3cc 100644
--- a/usr.bin/usbhidaction/usbhidaction.c
+++ b/usr.bin/usbhidaction/usbhidaction.c
@@ -165,7 +165,8 @@ main(int argc, char **argv)
if (demon) {
fp = open(pidfile, O_WRONLY|O_CREAT, S_IRUSR|S_IRGRP|S_IROTH);
if (fp >= 0) {
- sz1 = snprintf(buf, sizeof buf, "%d\n", getpid());
+ sz1 = snprintf(buf, sizeof buf, "%ld\n",
+ (long)getpid());
if (sz1 > sizeof buf)
sz1 = sizeof buf;
write(fp, buf, sz1);
OpenPOWER on IntegriCloud