diff --git a/LibOS/shim/src/ipc/shim_ipc_nsimpl.h b/LibOS/shim/src/ipc/shim_ipc_nsimpl.h index e5d0dc2d..d1ae5b92 100644 --- a/LibOS/shim/src/ipc/shim_ipc_nsimpl.h +++ b/LibOS/shim/src/ipc/shim_ipc_nsimpl.h @@ -362,7 +362,7 @@ int CONCAT3(add, NS, subrange) (IDTYPE idx, IDTYPE owner, goto failed; } - if ((err == __add_range(r, off, 0, NULL, 0)) < 0) { + if ((err = __add_range(r, off, 0, NULL, 0)) < 0) { free(r); goto failed; }