]> source.dussan.org Git - gitblit.git/commitdiff
Wrap pushlog update code with an exception handler, just-in-case
authorJames Moger <james.moger@gitblit.com>
Tue, 8 Jan 2013 20:19:28 +0000 (15:19 -0500)
committerJames Moger <james.moger@gitblit.com>
Tue, 8 Jan 2013 20:19:28 +0000 (15:19 -0500)
src/com/gitblit/GitServlet.java

index b55df04e9b9263fa998dbb8dfba3fa88d3c7455d..ff1ea7e9004527d0136dcb048e54056d97ca7406 100644 (file)
@@ -318,8 +318,12 @@ public class GitServlet extends org.eclipse.jgit.http.server.GitServlet {
                        }\r
 \r
                        // update push log\r
-                       PushLogUtils.updatePushLog(user, rp.getRepository(), commands);\r
-                       logger.info(MessageFormat.format("{0} push log updated", repository.name));\r
+                       try {\r
+                               PushLogUtils.updatePushLog(user, rp.getRepository(), commands);\r
+                               logger.info(MessageFormat.format("{0} push log updated", repository.name));\r
+                       } catch (Exception e) {\r
+                               logger.error(MessageFormat.format("Failed to update {0} pushlog", repository.name), e);\r
+                       }\r
                        \r
                        // run Groovy hook scripts \r
                        Set<String> scripts = new LinkedHashSet<String>();\r