Introduction
Introduction Statistics Contact Development Disclaimer Help
fix silly bug, dont read stdin ;) - sdhcp - simple dhcp client
git clone git://git.codemadness.org/sdhcp
Log
Files
Refs
LICENSE
---
commit 4f0cb77b97c5b7e907cd5b1e926a1d992f566995
parent 3acad37482310e721ce213ab49feecdd0b8719e0
Author: Hiltjo Posthuma <[email protected]>
Date: Sat, 26 Apr 2014 00:02:49 +0200
fix silly bug, dont read stdin ;)
mismatch braces so rnd evaluated to 0 (stdin).
Signed-off-by: Hiltjo Posthuma <[email protected]>
Diffstat:
M sdhcp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/sdhcp.c b/sdhcp.c
@@ -464,7 +464,7 @@ main(int argc, char *argv[])
ioctl(sock, SIOCGIFHWADDR, &ifreq);
memcpy(hwaddr, ifreq.ifr_hwaddr.sa_data, sizeof ifreq.ifr_hwaddr.sa_da…
- if((rnd = open("/dev/urandom", O_RDONLY) == -1))
+ if((rnd = open("/dev/urandom", O_RDONLY)) == -1)
eprintf("can't open /dev/urandom to generate unique transactio…
read(rnd, xid, sizeof xid);
close(rnd);
You are viewing proxied material from codemadness.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.