summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2013-09-12 07:11:11 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2013-09-12 07:11:11 +0000
commitb4d79c30e01a23670ca2b2a2c0be767ec475f64c (patch)
tree27cb773afbbaf0fe9ce0a11192d2c7054ccc8856
parente695e63169a4d0da7ab2fe77c59ac2ca29e443d1 (diff)
fixing coverity issues
-rw-r--r--src/transport/gnunet-helper-transport-wlan-dummy.c6
-rw-r--r--src/transport/gnunet-transport.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/transport/gnunet-helper-transport-wlan-dummy.c b/src/transport/gnunet-helper-transport-wlan-dummy.c
index 1e48d17e7..610b3a4c4 100644
--- a/src/transport/gnunet-helper-transport-wlan-dummy.c
+++ b/src/transport/gnunet-helper-transport-wlan-dummy.c
@@ -245,7 +245,7 @@ main (int argc, char *argv[])
{
if (0 != stat (FIFO_FILE2, &st))
{
- erg = mkfifo (FIFO_FILE2, 0666);
+ GNUNET_break (0 == (erg = mkfifo (FIFO_FILE2, 0666)));
if ( (0 != erg) && (EEXIST != errno) )
FPRINTF (stderr, "Error in mkfifo(%s): %s\n", FIFO_FILE2,
strerror (errno));
@@ -263,7 +263,7 @@ main (int argc, char *argv[])
}
if (NULL == (fpout = fopen (FIFO_FILE2, "w")))
{
- mkfifo (FIFO_FILE2, 0666);
+ GNUNET_break (0 == mkfifo (FIFO_FILE2, 0666));
fpout = fopen (FIFO_FILE2, "w");
}
if (NULL == fpout)
@@ -277,7 +277,7 @@ main (int argc, char *argv[])
first = 0;
if (NULL == (fpout = fopen (FIFO_FILE1, "w")))
{
- mkfifo (FIFO_FILE1, 0666);
+ GNUNET_break (0 == mkfifo (FIFO_FILE1, 0666));
fpout = fopen (FIFO_FILE1, "w");
}
if (NULL == fpout)
diff --git a/src/transport/gnunet-transport.c b/src/transport/gnunet-transport.c
index f9f606810..641261c05 100644
--- a/src/transport/gnunet-transport.c
+++ b/src/transport/gnunet-transport.c
@@ -487,7 +487,7 @@ transmit_data (void *cls, size_t size, void *buf)
{
struct GNUNET_MessageHeader *m = buf;
- if ((NULL == buf) || ((NULL == buf) && (0 == size)))
+ if ((NULL == buf) && (0 == size))
{
th = NULL;
return 0;