Commit f937e059 authored by Jacob Vosmaer's avatar Jacob Vosmaer

Stop git zombie creation during force push check

parent 2b10520b
...@@ -20,7 +20,7 @@ v 7.8.0 ...@@ -20,7 +20,7 @@ v 7.8.0
- -
- -
- -
- - Stop git zombie creation during force push check
- -
- -
- -
......
...@@ -4,7 +4,7 @@ module Gitlab ...@@ -4,7 +4,7 @@ module Gitlab
return false if project.empty_repo? return false if project.empty_repo?
if oldrev != Gitlab::Git::BLANK_SHA && newrev != Gitlab::Git::BLANK_SHA if oldrev != Gitlab::Git::BLANK_SHA && newrev != Gitlab::Git::BLANK_SHA
missed_refs = IO.popen(%W(git --git-dir=#{project.repository.path_to_repo} rev-list #{oldrev} ^#{newrev})).read missed_refs, _ = Gitlab::Popen.popen(%W(git --git-dir=#{project.repository.path_to_repo} rev-list #{oldrev} ^#{newrev}))
missed_refs.split("\n").size > 0 missed_refs.split("\n").size > 0
else else
false false
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment