diff options
| -rw-r--r-- | include/ouroboros/flow.h | 2 | ||||
| -rw-r--r-- | src/lib/flow.c | 2 | 
2 files changed, 2 insertions, 2 deletions
| diff --git a/include/ouroboros/flow.h b/include/ouroboros/flow.h index 456a85c7..7d8c311e 100644 --- a/include/ouroboros/flow.h +++ b/include/ouroboros/flow.h @@ -36,7 +36,7 @@  #define FLOW_O_NONBLOCK 00004000  #define FLOW_O_DEFAULT  00000002 -#define FLOW_O_INVALID  00037777 +#define FLOW_O_INVALID  (FLOW_O_WRONLY | FLOW_O_RDWR)  enum flow_state {          FLOW_INIT = 0, diff --git a/src/lib/flow.c b/src/lib/flow.c index ab9ad802..04166298 100644 --- a/src/lib/flow.c +++ b/src/lib/flow.c @@ -59,9 +59,9 @@ int flow_set_opts(flow_t * flow, uint16_t opts)          pthread_mutex_lock(&flow->lock);          if ((opts & FLOW_O_ACCMODE) == FLOW_O_ACCMODE) { +                flow->oflags = FLOW_O_DEFAULT;                  pthread_mutex_unlock(&flow->lock);                  LOG_WARN("Invalid flow options. Setting default."); -                opts = FLOW_O_DEFAULT;                  return -1;          } | 
