chiark
/
gitweb
/
~mdw
/
stgit
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
6c4e4b6
)
Fast-forwarding does a git.switch() even when it forwarded no patches
author
Chuck Lever
<cel@netapp.com>
Fri, 2 Dec 2005 00:15:13 +0000
(19:15 -0500)
committer
Catalin Marinas
<catalin.marinas@gmail.com>
Fri, 2 Dec 2005 21:47:00 +0000
(21:47 +0000)
The git.switch() in forward_patches() is not needed when no patches have
been fast forwarded. This is a significant speed up.
Signed-off-by: Chuck Lever <cel@netapp.com>
stgit/stack.py
patch
|
blob
|
blame
|
history
diff --git
a/stgit/stack.py
b/stgit/stack.py
index dc7c19f80136154ec3014479d1add66ced60ab1c..bc5915e727754bf26d61fc78e5a543885d0b9100 100644
(file)
--- a/
stgit/stack.py
+++ b/
stgit/stack.py
@@
-635,6
+635,9
@@
class Series:
forwarded+=1
unapplied.remove(name)
forwarded+=1
unapplied.remove(name)
+ if forwarded == 0:
+ return 0
+
git.switch(top)
append_strings(self.__applied_file, names[0:forwarded])
git.switch(top)
append_strings(self.__applied_file, names[0:forwarded])