diff --git a/lib/plat/unix/unix-file.c b/lib/plat/unix/unix-file.c index fe4960d7d..d9f4f1dc3 100644 --- a/lib/plat/unix/unix-file.c +++ b/lib/plat/unix/unix-file.c @@ -84,7 +84,7 @@ _lws_plat_file_open(const struct lws_plat_file_ops *fops_own, const char *vpath, lws_fop_flags_t *flags) { struct stat stat_buf; - int ret = lws_open(filename, (*flags) & LWS_FOP_FLAGS_MASK, 0664); + int ret = lws_open(filename, (int)((*flags) & LWS_FOP_FLAGS_MASK), 0664); lws_fop_fd_t fop_fd; if (ret < 0)