Messages in this thread Patch in this message | | | From | Aditya Pakki <> | Subject | [PATCH] udf: Fix to check the return value of load_nls | Date | Mon, 18 Mar 2019 21:59:49 -0500 |
| |
load_nls may fail and return an error message. The patch checks for such a scenario and passes the error upstream.
Signed-off-by: Aditya Pakki <pakki001@umn.edu> --- fs/udf/super.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/fs/udf/super.c b/fs/udf/super.c index ffd8038ff728..1a38271de6d9 100644 --- a/fs/udf/super.c +++ b/fs/udf/super.c @@ -573,6 +573,8 @@ static int udf_parse_options(char *options, struct udf_options *uopt, if (uopt->nls_map) unload_nls(uopt->nls_map); uopt->nls_map = load_nls(args[0].from); + if (!uopt->nls_map) + return 0; uopt->flags |= (1 << UDF_FLAG_NLS_MAP); } break; -- 2.17.1
| |