@matheusbsbs / matheus-bagliano / commits / 1f2de76981
Fork 0

upload-pack: Check for NOT_SHALLOW flag before sending a shallow to the client.

A commit may have been put on the shallow list, and then reached from another branch and marked NOT_SHALLOW without being removed from the list. Signed-off-by: Alexandre Julliard <julliard@winehq.org> Signed-off-by: Junio C Hamano <junkio@cox.net>

Alexandre Julliard committed Nov 24, 2006 at 15:58 UTC 1f2de769812f0adea598269d788c9c75d23e80b8
1 file changed +1 -1
upload-pack.c
+1 -1
@@ -565,7 +565,7 @@ static void receive_needs(void)
565 SHALLOW, NOT_SHALLOW);
566 while (result) {
567 struct object *object = &result->item->object;
568 - if (!(object->flags & CLIENT_SHALLOW)) {
568 + if (!(object->flags & (CLIENT_SHALLOW|NOT_SHALLOW))) {
569 packet_write(1, "shallow %s",
570 sha1_to_hex(object->sha1));
571 register_shallow(object->sha1);