From 31492c2f3a8b8a16eaffba0a50e7d381337e7397 Mon Sep 17 00:00:00 2001 From: csoler Date: Sun, 14 Jun 2015 09:49:21 +0000 Subject: [PATCH] fixed wrong use of flags in pqibin (wtf??) git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8431 b45a01b8-16f6-495d-af2f-9b41ad6348cc --- libretroshare/src/pqi/pqibin.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libretroshare/src/pqi/pqibin.h b/libretroshare/src/pqi/pqibin.h index 189a375b6..7b325b118 100644 --- a/libretroshare/src/pqi/pqibin.h +++ b/libretroshare/src/pqi/pqibin.h @@ -54,7 +54,7 @@ virtual int netstatus() { return 1;} virtual int isactive() { return (buf != NULL);} virtual bool moretoread(uint32_t /* usec */ ) { - if ((buf) && (bin_flags | BIN_FLAGS_READABLE)) + if ((buf) && (bin_flags & BIN_FLAGS_READABLE)) { if ((size - ftell(buf)) > 0) { @@ -67,7 +67,7 @@ virtual bool moretoread(uint32_t /* usec */ ) virtual int close(); virtual bool cansend(uint32_t /* usec */) { - return (bin_flags | BIN_FLAGS_WRITEABLE); + return (bin_flags & BIN_FLAGS_WRITEABLE); } virtual bool bandwidthLimited() { return false; } @@ -161,7 +161,7 @@ virtual int netstatus() { return 1; } virtual int isactive() { return 1; } virtual bool moretoread(uint32_t /* usec */) { - if ((buf) && (bin_flags | BIN_FLAGS_READABLE )) + if ((buf) && (bin_flags & BIN_FLAGS_READABLE )) { if (readloc < recvsize) { @@ -174,7 +174,7 @@ virtual bool moretoread(uint32_t /* usec */) virtual int close(); virtual bool cansend(uint32_t /* usec */) { - return (bin_flags | BIN_FLAGS_WRITEABLE); + return (bin_flags & BIN_FLAGS_WRITEABLE); } virtual bool bandwidthLimited() { return false; }