From: Junio C Hamano Date: Fri, 22 Feb 2013 20:49:16 GMT Subject: Re: [PATCH 2/2] read-cache.c: use INDEX_FORMAT_{LB,UB} in verify_hdr() Message-ID: <7vmwuwcbw3.fsf@alter.siamese.dyndns.org> In-Reply-To: <1361534964-4232-2-git-send-email-pclouds@gmail.com> Nguyễn Thái Ngọc Duy writes: > 9d22778 (read-cache.c: write prefix-compressed names in the index - > 2012-04-04) defined these. Interestingly, they were not used by > read-cache.c, or anywhere in that patch. They were used in > builtin/update-index.c later for checking supported index > versions. Use them here too. Thanks. > - if (hdr_version < 2 || 4 < hdr_version) > + if (hdr_version < INDEX_FORMAT_LB || > + hdr_version > INDEX_FORMAT_UB) > return error("bad index version %d", hdr_version);