diff --git a/gerrit-httpd/src/main/java/com/google/gerrit/httpd/restapi/ParameterParser.java b/gerrit-httpd/src/main/java/com/google/gerrit/httpd/restapi/ParameterParser.java index 4dd21aec61..f80cc498e9 100644 --- a/gerrit-httpd/src/main/java/com/google/gerrit/httpd/restapi/ParameterParser.java +++ b/gerrit-httpd/src/main/java/com/google/gerrit/httpd/restapi/ParameterParser.java @@ -66,7 +66,7 @@ class ParameterParser { CmdLineParser clp = parserFactory.create(param); try { clp.parseOptionMap(in); - } catch (CmdLineException e) { + } catch (CmdLineException | NumberFormatException e) { if (!clp.wasHelpRequestedByOption()) { replyError(req, res, SC_BAD_REQUEST, e.getMessage(), e); return false;