From: Alexandre Julliard Date: Fri, 24 Nov 2006 14:58:25 +0000 (+0100) Subject: upload-pack: Check for NOT_SHALLOW flag before sending a shallow to the client. X-Git-Tag: v1.5.0-rc1~172^2~4 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=1f2de769812f0adea598269d788c9c75d23e80b8;p=git.git 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 Signed-off-by: Junio C Hamano --- diff --git a/upload-pack.c b/upload-pack.c index d5b47507d..d4a7b625f 100644 --- a/upload-pack.c +++ b/upload-pack.c @@ -565,7 +565,7 @@ static void receive_needs(void) SHALLOW, NOT_SHALLOW); while (result) { struct object *object = &result->item->object; - if (!(object->flags & CLIENT_SHALLOW)) { + if (!(object->flags & (CLIENT_SHALLOW|NOT_SHALLOW))) { packet_write(1, "shallow %s", sha1_to_hex(object->sha1)); register_shallow(object->sha1);