Re: [PATCH v3 3/3] commit-slab: missing definitions and forward declarations (hdr-check)

2018-10-26 Thread Ramsay Jones
On 26/10/2018 04:15, Carlo Arenas wrote: > On Thu, Oct 25, 2018 at 2:09 PM Ramsay Jones > wrote: >> Yes, this will 'fix' the 'commit-reach.h' header (not surprising), >> but I prefer my patch. ;-) > > I apologize, I joined the list recently an

[PATCH 0/3] some more hdr-check clean headers

2018-10-26 Thread Ramsay Jones
aster (@c670b1f876) and merge without conflict to 'next' and with a 'minor' conflict on 'pu'. Ramsay Jones (3): fetch-object.h: add missing declaration (hdr-check) ewok_rlw.h: add missing 'inline' to function definition commit-reach.h: add missing decl

[PATCH 1/3] fetch-object.h: add missing declaration (hdr-check)

2018-10-26 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- fetch-object.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fetch-object.h b/fetch-object.h index d2f996d4e8..d6444caa5a 100644 --- a/fetch-object.h +++ b/fetch-object.h @@ -1,6 +1,8 @@ #ifndef FETCH_OBJECT_H #define FETCH_OBJECT_H +struct object_id

[PATCH 2/3] ewok_rlw.h: add missing 'inline' to function definition

2018-10-26 Thread Ramsay Jones
e ewah_bitmap.o and ewah_rlw.o object files. Despite this, add the missing 'inline' keyword to better describe the intended behaviour. Signed-off-by: Ramsay Jones --- ewah/ewok_rlw.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ewah/ewok_rlw.h b/ewah/ewok_rlw.h i

[PATCH 3/3] commit-reach.h: add missing declarations (hdr-check)

2018-10-26 Thread Ramsay Jones
nctions as external public functions in the git binary. At present, only three of these functions are actually called, so the trade-off seems to favour letting the compiler inline the commit-slab functions. Signed-off-by: Ramsay Jones --- commit-reach.h | 5 +++-- 1 file changed, 3 insertions(+),

Re: [PATCH 3/3] commit-reach.h: add missing declarations (hdr-check)

2018-10-29 Thread Ramsay Jones
On 29/10/2018 01:13, Junio C Hamano wrote: > Ramsay Jones writes: > >> ... >>24 clear_contains_cache >> $ >> >> you will find 24 copies of the commit-slab routines for the contains_cache. >> Of course, when you enable optimizations again, t

Re: [PATCH v2 12/16] parse-options: replace opterror() with optname()

2018-11-06 Thread Ramsay Jones
led from 'parse-options.c'. So, at present, optname() could be marked as a local 'static' symbol. However, I could also imagine it being used by new callers outside of 'parse-options.c' in the future. (maybe) Your call. ;-) ATB, Ramsay Jones

Re: [PATCH 1/1] mingw: handle absolute paths in expand_user_path()

2018-11-06 Thread Ramsay Jones
all 'included config' files? I am pretty sure that I would not want the absolute paths in my config file(s) magically 'moved' depending on whether git has been compiled with 'runtime prefix' support or not! ATB, Ramsay Jones > if (path[0] == '~') { > const char *first_slash = strchrnul(path, '/'); > const char *username = path + 1; >

Re: [PATCH 1/1] mingw: handle absolute paths in expand_user_path()

2018-11-06 Thread Ramsay Jones
On 06/11/2018 15:54, Ramsay Jones wrote: > > > On 06/11/2018 14:53, Johannes Schindelin via GitGitGadget wrote: >> From: Johannes Schindelin >> >> On Windows, an absolute POSIX path needs to be turned into a Windows >> one. >> >> Signed-off-b

Re: [PATCH 1/1] mingw: handle absolute paths in expand_user_path()

2018-11-07 Thread Ramsay Jones
cover letter: The reason is this: something like this (make paths specified e.g. via http.sslCAInfo relative to the runtime prefix) is potentially useful also in the non-Windows context, as long as Git was built with the runtime prefix feature. ... so I thought you meant to add this code for POSIX systems as well. My mistake. :( ATB, Ramsay Jones

Re: [PATCH v2 12/16] parse-options: replace opterror() with optname()

2018-11-10 Thread Ramsay Jones
On 10/11/2018 04:55, Duy Nguyen wrote: > On Tue, Nov 6, 2018 at 3:07 PM Ramsay Jones > wrote: >> Also, this patch does not replace opterror() calls outside of >> the 'parse-options.c' file with optname(). This tickles my >> static-check.pl script, since

Re: [PATCH 3/9] rename "alternate_object_database" to "object_directory"

2018-11-12 Thread Ramsay Jones
not set in stone. I also like that "odb" is the same short > length as "alt", which helps with conversion. While reading the patch, I keep thinking it should be 'obd' for OBject Directory. ;-) [Given my track record in naming things, please take with a _huge_ pinch of salt!] ATB, Ramsay Jones

Re: [PATCH v5 02/12] sha1-file: provide functions to look up hash algorithms

2018-11-13 Thread Ramsay Jones
a1-file.o - hash_algo_by_name $ The symbols from hex.o and sha1-file.o being the 4 symbols from this branch. I suspect that upcoming patches will make use of them. ;-) ATB, Ramsay Jones

Re: [PATCH v5 02/12] sha1-file: provide functions to look up hash algorithms

2018-11-13 Thread Ramsay Jones
On 14/11/2018 00:11, Ramsay Jones wrote: > > > On 13/11/2018 18:42, Derrick Stolee wrote: >> On 11/4/2018 6:44 PM, brian m. carlson wrote: >>> +int hash_algo_by_name(const char *name) >>> +{ >>> +    int i; >>> +    if (!name) >>&

Re: [PATCH v5 02/12] sha1-file: provide functions to look up hash algorithms

2018-11-13 Thread Ramsay Jones
On 14/11/2018 02:11, brian m. carlson wrote: > On Wed, Nov 14, 2018 at 12:11:07AM +0000, Ramsay Jones wrote: >> >> >> On 13/11/2018 18:42, Derrick Stolee wrote: >>> On 11/4/2018 6:44 PM, brian m. carlson wrote: >>>> +int hash_algo_by_name(const char *n

Re: [PATCH v5] clone: report duplicate entries on case-insensitive filesystems

2018-11-19 Thread Ramsay Jones
ok 98 - clone on case-insensitive fs ok 99 # skip colliding file detection (missing !CYGWIN of !MINGW,!CYGWIN,CASE_INSENSITIVE_FS) ok 100 - partial clone ok 101 - partial clone: warn if server does not support object filtering ok 102 - batch missing blob request during checkout ok 103 - batch missing blob request does not inadvertently try to fetch gitlinks # passed all 103 test(s) # SKIP no web server found at '/usr/sbin/apache2' 1..103 $ ATB, Ramsay Jones

Re: [PATCH v5] clone: report duplicate entries on case-insensitive filesystems

2018-11-19 Thread Ramsay Jones
v: 2378432 ino: 324352 uid: 1001 gid: 513 size: 0 flags: 0 x ctime: 1542667201:665026800 mtime: 1542667201:665026800 dev: 2378432 ino: 324352 uid: 1001 gid: 513 size: 0 flags: 0 $ So, both X and x are in the index with the same inode number. Does that help? ATB, Ramsay Jones

Re: [PATCH v5] clone: report duplicate entries on case-insensitive filesystems

2018-11-19 Thread Ramsay Jones
On 19/11/2018 23:29, Ramsay Jones wrote: > > > On 19/11/2018 21:03, Duy Nguyen wrote: >> First of all, Ramsay, it would be great if you could test the below >> patch and see if it works on Cygwin. I assume since Cygwin shares the >> underlying filesystem, it will

Re: [PATCH] clone: fix colliding file detection on APFS

2018-11-20 Thread Ramsay Jones
or even on APFS when inode numbers are still > below 2^32. > > Or we just to to reduce the odds of matching a wrong file by checking > more attributes, counting mostly on st_size because st_xtime is likely > the same. This patch goes with this direction, hoping that false > positive

Re: [PATCH 0/9] worktree: fix bugs and broaden --force applicability

2018-08-31 Thread Ramsay Jones
On 31/08/18 01:54, Jeff King wrote: > On Fri, Aug 31, 2018 at 12:49:39AM +0100, Ramsay Jones wrote: > >> On 30/08/18 21:14, Junio C Hamano wrote: >>> Jeff King writes: >>> >>>> I suppose so. I don't think I've _ever_ used distclean, an

Re: git silently ignores include directive with single quotes

2018-09-08 Thread Ramsay Jones
path = ... I was going to suggest, inspired by Makefile syntax, that [-include] would not complain if the file was missing ... except, of course, it's too late for that! ;-) I suppose [+include] could complain if the file is missing instead, ... dunno. ATB, Ramsay Jones

Re: [PATCH 1/9] string-list: add string_list_{pop, last} functions

2018-09-11 Thread Ramsay Jones
list); > > work_on(item); > string_list_pop(&list); string_list_pop() takes a second int parameter (free_util). ATB, Ramsay Jones

Re: [PATCH 6/9] submodule.c: do not copy around submodule list

2018-09-11 Thread Ramsay Jones
items afterwards > using string_list_remove_empty_items. > > By doin so we'll have access to the util pointer for longer that s/doin/doing/ ATB, Ramsay Jones

[PATCH] midx.c: mark a file-local symbol as static

2018-09-14 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Derrick, If you need to re-roll your 'ds/multi-pack-verify' branch, could you please squash this into the relevant patch (commit 64cbf3df21, "multi-pack-index: add 'verify' verb", 2018-09-13). [noticed by sparse]. Thanks.

[PATCH] read-cache.c: fix a sparse warning

2018-09-14 Thread Ramsay Jones
th NO_PTHREADS set). In order to fix the warning, move the (conditional) pthread field to the end of the struct and change the initialiser to use a NULL, since the new (unconditional) first field is a pointer type. Signed-off-by: Ramsay Jones --- Hi Ben, If you need to re-roll your 'bp/rea

Re: [PATCH] read-cache.c: fix a sparse warning

2018-09-17 Thread Ramsay Jones
On 17/09/18 15:15, Ben Peart wrote: > > > On 9/16/2018 3:17 AM, Eric Sunshine wrote: >> On Fri, Sep 14, 2018 at 7:29 PM Ramsay Jones >> wrote: >>> At one time, the POSIX standard required the type used to represent >>> a thread handle (pthread_t) b

Re: [PATCH] read-cache.c: fix a sparse warning

2018-09-17 Thread Ramsay Jones
On 17/09/18 17:27, Ramsay Jones wrote: > > > On 17/09/18 15:15, Ben Peart wrote: >> >> >> On 9/16/2018 3:17 AM, Eric Sunshine wrote: >>> On Fri, Sep 14, 2018 at 7:29 PM Ramsay Jones >>> wrote: >>>> At one time, the POSIX standard

Subject: [PATCH 0/9] hdr-check

2018-09-18 Thread Ramsay Jones
ranch. [1] https://public-inbox.org/git/b8553a50-6b97-2b45-2f7b-cfe257654...@ramsayjones.plus.com/ ATB, Ramsay Jones Ramsay Jones (9): Makefile: add a hdr-check target json-writer.h: add missing include (hdr-check) ewah/ewok_rlw.h: add missing include (hdr-check) refs/ref-cache.h: add

[PATCH 1/9] Makefile: add a hdr-check target

2018-09-18 Thread Ramsay Jones
that individual header files can be checked directly using the '.hco' extension (read: Hdr-Check Object) like so: $ make config.hco HDR config.h $ Signed-off-by: Ramsay Jones --- Makefile | 12 1 file changed, 12 insertions(+) diff --git a/Makefile b/Makef

[PATCH 2/9] json-writer.h: add missing include (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- json-writer.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/json-writer.h b/json-writer.h index fc18acc7d9..83906b09c1 100644 --- a/json-writer.h +++ b/json-writer.h @@ -42,6 +42,8 @@ * of the given strings. */ +#include "strbuf.h"

[PATCH 3/9] ewah/ewok_rlw.h: add missing include (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- ewah/ewok_rlw.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ewah/ewok_rlw.h b/ewah/ewok_rlw.h index 7cdfdd0c02..d487966935 100644 --- a/ewah/ewok_rlw.h +++ b/ewah/ewok_rlw.h @@ -19,6 +19,8 @@ #ifndef __EWOK_RLW_H__ #define __EWOK_RLW_H__ +#include

[PATCH 4/9] refs/ref-cache.h: add missing declarations (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- refs/ref-cache.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/refs/ref-cache.h b/refs/ref-cache.h index eda65e73ed..3bfb89d2b3 100644 --- a/refs/ref-cache.h +++ b/refs/ref-cache.h @@ -1,7 +1,10 @@ #ifndef REFS_REF_CACHE_H #define REFS_REF_CACHE_H

[PATCH 5/9] refs/packed-backend.h: add missing declaration (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- refs/packed-backend.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/refs/packed-backend.h b/refs/packed-backend.h index 640245d3b9..a01a0aff9c 100644 --- a/refs/packed-backend.h +++ b/refs/packed-backend.h @@ -1,6 +1,8 @@ #ifndef REFS_PACKED_BACKEND_H

[PATCH 6/9] refs/refs-internal.h: add missing declarations (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- refs/refs-internal.h | 4 1 file changed, 4 insertions(+) diff --git a/refs/refs-internal.h b/refs/refs-internal.h index 04425d6d1e..44d53672c7 100644 --- a/refs/refs-internal.h +++ b/refs/refs-internal.h @@ -1,8 +1,12 @@ #ifndef REFS_REFS_INTERNAL_H

[PATCH 7/9] midx.h: add missing forward declarations (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- midx.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/midx.h b/midx.h index a210f1af2a..622ddac472 100644 --- a/midx.h +++ b/midx.h @@ -3,6 +3,9 @@ #include "repository.h" +struct object_id; +struct pack_entry; + struct multi_

[PATCH 8/9] delta-islands.h: add missing forward declarations (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- delta-islands.h | 4 1 file changed, 4 insertions(+) diff --git a/delta-islands.h b/delta-islands.h index f9725730f4..b635cd07d8 100644 --- a/delta-islands.h +++ b/delta-islands.h @@ -1,6 +1,10 @@ #ifndef DELTA_ISLANDS_H #define DELTA_ISLANDS_H +struct

[PATCH 9/9] commit-reach.h: add missing declarations (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- commit-reach.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/commit-reach.h b/commit-reach.h index 7d313e2975..f41d8f6ba3 100644 --- a/commit-reach.h +++ b/commit-reach.h @@ -1,12 +1,13 @@ #ifndef __COMMIT_REACH_H__ #define

[PATCH] fetch-object.h: add missing declaration (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Junio, This is the patch I needed for the current 'next' branch to get a clean 'hdr-check' ATB, Ramsay Jones fetch-object.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fetch-object.h b/fetch-object.h index d2f996d4e8..d64

[PATCH] userdiff.h: add missing declaration (hdr-check)

2018-09-18 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Junio, ... and this is the patch I needed for the current 'pu' branch. ATB, Ramsay Jones userdiff.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/userdiff.h b/userdiff.h index dad3fc03c1..b072bfe89a 100644 --- a/userdiff.h +++ b/userdiff

Re: [PATCH 1/9] Makefile: add a hdr-check target

2018-09-19 Thread Ramsay Jones
On 19/09/18 18:49, Martin Ågren wrote: > Hi Ramsay, > > On Wed, 19 Sep 2018 at 02:07, Ramsay Jones > wrote: >> @@ -2675,6 +2676,17 @@ $(SP_OBJ): %.sp: %.c GIT-CFLAGS FORCE >> .PHONY: sparse $(SP_OBJ) >> sparse: $(SP_OBJ) >> >> +GEN_HDRS := comma

Re: [PATCH 9/9] commit-reach.h: add missing declarations (hdr-check)

2018-09-20 Thread Ramsay Jones
On 20/09/18 00:38, Derrick Stolee wrote: > On 9/18/2018 8:15 PM, Ramsay Jones wrote: >> Signed-off-by: Ramsay Jones >> --- >>   commit-reach.h | 5 +++-- >>   1 file changed, 3 insertions(+), 2 deletions(-) >> >> diff --git a/commit-reach.h b/commit-

Re: [PATCH 1/9] Makefile: add a hdr-check target

2018-09-20 Thread Ramsay Jones
On 20/09/18 15:26, Junio C Hamano wrote: > Ramsay Jones writes: > >> Commit ef3ca95475 ("Add missing includes and forward declarations", >> 2018-08-15) resulted from the author employing a manual method to >> create a C file consisting of a pair of pre-pro

Re: [PATCH] fetch-object.h: add missing declaration (hdr-check)

2018-09-21 Thread Ramsay Jones
On 21/09/18 17:21, Junio C Hamano wrote: > Ramsay Jones writes: > >> Signed-off-by: Ramsay Jones >> --- >> >> Hi Junio, >> >> This is the patch I needed for the current 'next' branch to get >> a clean 'hdr-check' > >

[PATCH] fetch: fix compilation warning

2018-09-27 Thread Ramsay Jones
commit 440fc7c0729 ("fetch: replace string-list used as a look-up table with a hashmap", 2018-09-25) renamed a string-list variable (while adding a hashmap of the same name) and forgot to rename the string-list variable in a call to string_list_clear(). Signed-off-by: Ramsay Jone

[PATCH] read-cache: fix division by zero core-dump

2018-09-27 Thread Ramsay Jones
ite, until test t4056-diff-order.sh, which then went into an infinite loop! Signed-off-by: Ramsay Jones --- Hi Ben, Could you please squash this into the relevant commits on your 'bp/read-cache-parallel' branch. (The first hunk fixes a sparse warning about using an integer as a NUL

Re: [PATCH] read-cache: fix division by zero core-dump

2018-09-28 Thread Ramsay Jones
On 28/09/18 02:20, Ben Peart wrote: > > > On 9/27/2018 6:24 PM, Ramsay Jones wrote: >> >> commit 225df8a468 ("ieot: add Index Entry Offset Table (IEOT) >> extension", 2018-09-26) added a 'DIV_ROUND_UP(entries, ieot_blocks) >> expression, wh

Re: [PATCH v6 4/7] config: add new index.threads config setting

2018-09-28 Thread Ramsay Jones
= istate->cache_nr / THREAD_COST; > -       if (ieot_blocks < 1) > -   ieot_blocks = 1; >     cpus = online_cpus(); >     if (ieot_blocks > cpus - 1) >     ieo

Re: [PATCH v4 4/4] transport.c: introduce core.alternateRefsPrefixes

2018-10-02 Thread Ramsay Jones
t; && > + git rev-parse private/branch expect && s/expect/>expect/ ? ATB, Ramsay Jones > + printf "" | git receive-pack fork >actual && > + extract_haves actual.haves && > + test_cmp expect actual.haves > +' &g

Re: [PATCH] zlib.c: use size_t for size

2018-10-12 Thread Ramsay Jones
The primary reason was that >> nobody tried to dust it off and reignite the topic so far---which I >> am trying to correct, but as I said, this is just minimally adjusted >> to today's codebase, without any attempt to improve relative to the >> original patch. &g

Re: [PATCH v2 1/1] zlib.c: use size_t for size

2018-10-13 Thread Ramsay Jones
built this on MINGW32 and MINGW64 along with some light manual testing (the test suite has never passed on Msys2 for me). This is not the same as testing on Gfw, of course. ATB, Ramsay Jones -- >8 -- From: Martin Koegler Subject: [PATCH v3 1/1] zlib.c: use size_t for size Signed-off-by: Mar

Re: [PATCH v2 1/1] zlib.c: use size_t for size

2018-10-13 Thread Ramsay Jones
On 14/10/18 03:16, Ramsay Jones wrote: > > > On 13/10/18 06:00, Torsten Bögershausen wrote: >> [] >>> Neither v1 nor v2 of this patch compiles on 32 bit Linux; see >>> >>> https://travis-ci.org/git/git/jobs/440514375#L628 >>> >>> T

Re: [PATCH v2 1/1] zlib.c: use size_t for size

2018-10-14 Thread Ramsay Jones
On 14/10/18 03:52, Jeff King wrote: > On Sun, Oct 14, 2018 at 03:16:36AM +0100, Ramsay Jones wrote: > >> diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c >> index b059b86aee..3b5f2c38b3 100644 >> --- a/builtin/pack-objects.c >> +++ b/builtin/pack-o

[RFC/PATCH] headers: normalize the spelling of some header guards

2018-10-14 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Junio, This patch is marked RFC because I am not aware of any policy with regard to header guard spelling. Having said that, apart from the fetch-negotiator.h header, all of these headers are using a reserved identifier (see C99 Standard 7.1.3). These

Re: [RFC/PATCH] headers: normalize the spelling of some header guards

2018-10-14 Thread Ramsay Jones
On 15/10/18 00:59, Jeff King wrote: > On Sun, Oct 14, 2018 at 09:13:09PM +0100, Ramsay Jones wrote: > >> This patch is marked RFC because I am not aware of any policy with >> regard to header guard spelling. Having said that, apart from the >> fetch-negotiator.h head

Re: [PATCH v2 1/1] zlib.c: use size_t for size

2018-10-14 Thread Ramsay Jones
On 15/10/18 01:01, Jeff King wrote: > On Sun, Oct 14, 2018 at 04:03:48PM +0100, Ramsay Jones wrote: > >>> So I kind of wonder if a comment would be better than xsize_t here. >>> Something like: >>> >>> if (avail > len) { >>> /* >&

[PATCH v2] headers: normalize the spelling of some header guards

2018-10-17 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Junio, Since I didn't get any adverse comments, this version has the RFC label removed. Also, given that it seems the vcs-svn directory is not going away soon, I have included those headers this time as well. [Note: my email client (thunderbird) was up

Re: [PATCH] config.mak.dev: enable -Wunused-function

2018-10-18 Thread Ramsay Jones
deeply, but this seems to be caused by Junio's commit 42c89ea70a ("SQUASH??? - convert the other user of string-list as db", 2018-10-17) which removes a call to the add_existing() function - the subject of the warning. [BTW there is another 'static add_existing()' in builtin/show_ref.c] ATB, Ramsay Jones

Re: [RFC PATCH 4/7] merge-recursive: fix assumption that head tree being merged is HEAD

2018-06-03 Thread Ramsay Jones
dex_has_changes() declaration should go; > I stuck it in tree.h, but is there a better spot? Err, leave it where it is and '#include "tree.h"' ? :-D ATB, Ramsay Jones

Re: [RFC PATCH 4/7] merge-recursive: fix assumption that head tree being merged is HEAD

2018-06-03 Thread Ramsay Jones
On 04/06/18 00:37, brian m. carlson wrote: > On Sun, Jun 03, 2018 at 02:52:12PM +0100, Ramsay Jones wrote: >> On 03/06/18 07:58, Elijah Newren wrote: >>> I'm really unsure where the index_has_changes() declaration should go; >>> I stuck it in tree.h, but is there

Re: [PATCH v7 2/2] http-backend: respect CONTENT_LENGTH for receive-pack

2018-06-04 Thread Ramsay Jones
case) is needed? As far as I can see n > returns straight from system's read() ATB, Ramsay Jones

Re: [PATCH 3/6] unpack-trees: don't shadow global var the_index

2018-06-05 Thread Ramsay Jones
> -select_flag, skip_wt_flag, el); > + clear_ce_flags(istate, select_flag, skip_wt_flag, el); This looks a bit suspect. The clear_ce_flags() function has not been modified to take a 'struct index_state *' as its first parameter, right? (If you look back at the first hunk header, you will see that it still takes 'struct cache_entry **, int, ...') ;-) ATB, Ramsay Jones

Re: [PATCH 4/6] unpack-tress: convert clear_ce_flags* to avoid the_index

2018-06-05 Thread Ramsay Jones
t; return nr - (cache_end - cache); > } > > -static int clear_ce_flags(struct cache_entry **cache, int nr, > - int select_mask, int clear_mask, > - struct exclude_list *el) > +static int clear_ce_flags(struct index_state *istate, > + int select_mask, int clear_mask, > + struct exclude_list *el) OK, so that last hunk of patch #3 should be moved to the end of this patch. (A 'git rebase -i' problem?) ATB, Ramsay Jones

Re: [PATCH 2/8] upload-pack: implement ref-in-want

2018-06-05 Thread Ramsay Jones
shallow-info | wanted-refs | packfile) > (flush-pkt | delim-pkt) > > acknowledgments = PKT-LINE("acknowledgments" LF) > @@ -319,6 +328,10 @@ header. > shallow = "shallow" SP obj-id > unshallow = "unshallow" SP obj-id > > +wanted-refs = PKT-LINE("wanted-refs" LF) > + *PKT-Line(wanted-ref LF) s/PKT-Line/PKT-LINE/ ATB, Ramsay Jones

Re: [PATCH v3 07/20] attr: remove an implicit dependency on the_index

2018-06-06 Thread Ramsay Jones
se the right index instead of the_index. > > There is one ugly temporary workaround added in attr.c that needs some > more explanation. > > Commit c24f3abace (apply: file commited * with CRLF should roundtrip s/commited * with/commited with/ ATB, Ramsay Jones

Re: [PATCH v7 2/2] json-writer: t0019: add Python unit test

2018-06-06 Thread Ramsay Jones
$git/$file" >"$scrub" && t/t9810-git-p4-rcs.sh: "$PYTHON_PATH" "$TRASH_DIRECTORY/scrub_ko.py" <"$git/$file" >"$scrub" && $ I don't run the p4 or svn tests, so ... :-D > really the only user in the whole code base outside of a few fringe > commands). Leaving aside any perl vs python flame-war, I think there's > value in keeping the number of languages limited when there's not a > compelling reason to do otherwise. I agree that fewer languages is (generally) a good idea. ATB, Ramsay Jones

Re: [PATCH v7 2/2] json-writer: t0019: add Python unit test

2018-06-07 Thread Ramsay Jones
On 07/06/18 03:23, Jeff King wrote: > On Thu, Jun 07, 2018 at 01:16:14AM +0100, Ramsay Jones wrote: > >>> Probably. We may want to go the same route as we did for perl in >>> a0e0ec9f7d (t: provide a perl() function which uses $PERL_PATH, >>> 2013-10-28) s

Re: [PATCH 3/3] ewah: drop ewah_serialize_native function

2018-06-15 Thread Ramsay Jones
n to these *(de)serialize* functions. ;-) ATB, Ramsay Jones

Re: [PATCH 3/3] ewah: drop ewah_serialize_native function

2018-06-15 Thread Ramsay Jones
On 15/06/18 14:56, Ramsay Jones wrote: > > > On 15/06/18 04:32, Jeff King wrote: >> We don't call this function, and never have. The on-disk >> bitmap format uses network-byte-order integers, meaning that >> we cannot use the native-byte-order format written

Re: [PATCH 1/8] ewah/bitmap.c: delete unused 'bitmap_clear()'

2018-06-15 Thread Ramsay Jones
On 15/06/18 15:30, Derrick Stolee wrote: > Reported-by: Ramsay Jones > Signed-off-by: Derrick Stolee > --- > ewah/bitmap.c | 8 > 1 file changed, 8 deletions(-) > > diff --git a/ewah/bitmap.c b/ewah/bitmap.c > index 756bdd050e..d61dc6114a 100644 > --- a

Re: [PATCH 8/8] ewah_io: delete unused 'ewah_serialize_native()'

2018-06-15 Thread Ramsay Jones
On 15/06/18 15:30, Derrick Stolee wrote: > Signed-off-by: Derrick Stolee > --- > ewah/ewah_io.c | 26 -- > ewah/ewok.h| 1 - > 2 files changed, 27 deletions(-) This duplicates Jeff's patch #3. ATB, Ramsay Jones

Re: [PATCH 2/8] ewah/bitmap.c: delete unused 'bitmap_each_bit()'

2018-06-15 Thread Ramsay Jones
On 15/06/18 15:30, Derrick Stolee wrote: > Reported-by: Ramsay Jones > Signed-off-by: Derrick Stolee > --- > ewah/bitmap.c | 24 > 1 file changed, 24 deletions(-) > > diff --git a/ewah/bitmap.c b/ewah/bitmap.c > index d61dc6114a..52f117

[PATCH] ewah: delete unused 'rlwit_discharge_empty()'

2018-06-19 Thread Ramsay Jones
From: Junio C Hamano Complete the removal of unused 'ewah bitmap' code by removing the now unused 'rlwit_discharge_empty()' function. Also, the 'ewah_clear()' function can now be made a file-scope static symbol. Signed-off-by: Ramsay Jones --- Hi Junio, Can

[PATCH] diff: fix a sparse 'dubious one-bit signed bitfield' error

2018-06-23 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Stefan, If you need to re-roll your 'sb/diff-color-move-more' branch, could you please squash this into the relevant patch (commit f2d78d2c67, "diff.c: add white space mode to move detection that allows indent changes", 2018-06-21).

[PATCH] fsck: check skiplist for object in fsck_blob()

2018-06-27 Thread Ramsay Jones
ct, a simpler approach is to just not call the config parser if the object is to be skipped. Add a check to the 'fsck_blob()' processing function, to determine if the object is on the skiplist and, if so, exit the function early. Signed-off-by: Ramsay Jones --- Hi Junio, I noticed recent

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-06-28 Thread Ramsay Jones
On 28/06/18 12:49, Jeff King wrote: > On Wed, Jun 27, 2018 at 07:39:53PM +0100, Ramsay Jones wrote: > >> Since commit ed8b10f631 ("fsck: check .gitmodules content", 2018-05-02), >> fsck will issue an error message for '.gitmodules' content that cannot &g

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-06-28 Thread Ramsay Jones
On 28/06/18 18:45, Jeff King wrote: > On Thu, Jun 28, 2018 at 05:56:18PM +0100, Ramsay Jones wrote: [snip] >>> One thing we could do is turn the parse failure into a noop. The main >>> point of the check is to protect people against the malicious >>> .gitmodules bu

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-06-28 Thread Ramsay Jones
On 28/06/18 23:03, Jeff King wrote: > On Thu, Jun 28, 2018 at 07:53:27PM +0100, Ramsay Jones wrote: [snip] > Yes, it can go in quickly. But I'd prefer not to keep it in the long > term if it's literally doing nothing. Hmm, I don't think you can say its doing nothing!

Re: [PATCH 4/4] fsck: silence stderr when parsing .gitmodules

2018-06-28 Thread Ramsay Jones
gt; But that seems even more far-fetched. And it _is_ dangerous to leave, > because I think existing vulnerable clients will try to load a 500MB > .gitmodules file in memory and parse it. I also applied and tested the patch below. I think this patch must be included in the series. ATB, Ramsay

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-07-03 Thread Ramsay Jones
On 03/07/18 15:34, Jeff King wrote: > On Fri, Jun 29, 2018 at 02:10:59AM +0100, Ramsay Jones wrote: > >> On 28/06/18 23:03, Jeff King wrote: >>> On Thu, Jun 28, 2018 at 07:53:27PM +0100, Ramsay Jones wrote: >> [snip] >>> Yes, it can go in quickly. But I

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-07-11 Thread Ramsay Jones
; /* infos (reported as warnings, but ignored by default) */ \ > FUNC(BAD_TAG_NAME, INFO) \ > + FUNC(GITMODULES_PARSE, INFO) \ > FUNC(MISSING_TAGGER_ENTRY, INFO) > > #define MSG_ID(id, msg_type) FSCK_MSG_##id, > So, just squinting at this in my email client, if this allowed a push/fetch to succeed (along with an 'info' message), while providing an admin the means to configure it to loudly deny the push/fetch - then I think we have a winner! ;-) Sorry for not testing the patch. ATB, Ramsay Jones

[PATCH] t6036: fix broken && chain in sub-shell

2018-07-12 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Junio, I had a test failure on 'pu' today - Eric's chain-lint series found another broken chain in one of Elijah's new tests (on the 'en/t6036-recursive-corner-cases' branch). ATB, Ramsay Jones t/t6036-recursive-corner-case

[PATCH] ref-filter: mark some file-local symbols as static

2018-07-12 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Olga, If you need to re-roll your 'ot/ref-filter-object-info' branch, could you please squash this into the relevant patch (commit c5d9a471d6, "ref-filter: use oid_object_info() to get object", 2018-07-09). [Both sparse and my static

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-07-13 Thread Ramsay Jones
On 11/07/18 20:31, Ramsay Jones wrote: > On 07/07/18 02:32, Jeff King wrote: [snip] >> Hmm, we seem to have "info" these days, so maybe that would do what I >> want. I.e., I wonder if the patch below does everything we'd want. It's >> late here and I pro

Re: [PATCH] fsck: check skiplist for object in fsck_blob()

2018-07-13 Thread Ramsay Jones
re > slightly redundant (well, not redundant if you're into black-box > testing, but our current tests are usually written with an assumption of > where the module boundaries are, and what is likely to be a problem). I don't mind either way. I will let you and Junio decide. Thanks! ATB, Ramsay Jones

Re: [PATCH 00/16] Consolidate reachability logic

2018-07-16 Thread Ramsay Jones
I hate it), be even with that turned on, the patches still appear in the above order under the cover letter (but at least all together). Annoyed. ATB, Ramsay Jones

Re: Confusion about the PACK format

2019-02-10 Thread Ramsay Jones
#x27; ... We can use git-verify-pack to confirm the details here: $ git verify-pack -v .git/objects/pack/pack-d554e6d8335601c2525b40487faf36493094ab50.idx | head -n 1 878e2cd30e1656909c5073043d32fe9d02204daa commit 317 216 12 $ So the object 878e2cd30e, at offset 12 in the file, is a commit object with size 317 (which has an in-pack size of 216). Hope this helps. ATB, Ramsay Jones

Re: Confusion about the PACK format

2019-02-10 Thread Ramsay Jones
On 10/02/2019 19:05, Ramsay Jones wrote: > > > On 10/02/2019 16:02, Florian Steenbuck wrote: >> Hello to all, >> >> I try to understand the git protocol only on the server site. So I >> start without reading any docs and which turns to be fine until I got &g

[PATCH] sequencer: make sign_off_header a file local symbol

2019-02-11 Thread Ramsay Jones
static keyword. Signed-off-by: Ramsay Jones --- Hi Junio, This has been hanging around for a while. I sent it to the list last time in [1], but it seems to have been dropped. (Found while attempting to rebase loads of old branches to a newer base!) ATB, Ramsay Jones [1] https://public-inbox.o

[PATCH] prune-packed: check for too many arguments

2019-02-11 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi Junio, Another 'old find' (from feb 2017), but this time I don't seem to have sent this one to the list before. It is possible that I didn't think it was up to scratch ... dunno. ;-) ATB, Ramsay Jones builtin/prune-packed.c | 5

Re: [PATCH v2] read-cache: add post-indexchanged hook

2019-02-14 Thread Ramsay Jones
t > the outcome of git commands that trigger the index write. > > The hook is passed a flag to indicate whether the working directory was > updated or not and a flag indicating if a skip-worktree bit could have > changed. These flags enable the hook to optmize its response to the

Re: [Fix v1] builtin/ls-files.c: add error check on lstat for modified files

2019-02-17 Thread Ramsay Jones
err = lstat(fullname.buf, &st); > if (show_deleted && err) To be pedantic, this should probably check for (err == ENOENT), since lstat() can fail for several reasons which don't imply that the path has been deleted. However, that is

Re: [PATCH v2 1/1] worktree add: sanitize worktree names

2019-02-21 Thread Ramsay Jones
(i < name->len - 1 && name->buf[i + 1] == '-'))) > + strbuf_remove(name, i, 1); > + } > + > + /* > + * a worktree name of only special chars would be reduced to > + * an empty string > + */> + if (name->len == 0) > + strbuf_addstr(name, "worktree"); If you didn't 'collapse' the name above, you could check for an empty name at the top and wouldn't need this (presumably an empty name would not be valid). ATB, Ramsay Jones

Re: [PATCH v2 2/6] Makefile: move "strip" assignment down from flags

2019-02-22 Thread Ramsay Jones
origin command line $ So does the environment: $ CC=env make CC is env, origin environment $ But that conditional assignment: $ make CC is cc, origin default $ ... not so much! :-D ATB, Ramsay Jones

Re: [PATCH 1/1] Makefile: use `git ls-files` to list header files, if possible

2019-03-03 Thread Ramsay Jones
for some unrelated headers in your worktree, then we can only use a static list, or a 'git ls-files' approach. Anyway, for now, since I seem to be the only person using this target, I think we should just remove it while I think again. (I can put it in my config.mak, so there will be no loss for me). ATB, Ramsay Jones

[PATCH] Makefile: remove the 'hdr-check' target

2019-03-03 Thread Ramsay Jones
Makefile: add a hdr-check target", 2018-09-19). Signed-off-by: Ramsay Jones --- Makefile | 12 1 file changed, 12 deletions(-) diff --git a/Makefile b/Makefile index c5240942f2..dd3e38dc1f 100644 --- a/Makefile +++ b/Makefile @@ -1852,7 +1852,6 @@ ifndef V QUIET_MSGFMT

Re: [PATCH 1/1] Makefile: use `git ls-files` to list header files, if possible

2019-03-04 Thread Ramsay Jones
back to your wildcard idea if > `ls-files` fails for some reason (typically because `.git/` is missing, > e.g. in case of an unpacked source .tar). Yes, I think an 'git ls-files' approach is the way to go. (I am not sure that the 'hdr-check' target would be of any use 'offline' at all, but I suppose we could use a generated file in that case). >> Anyway, for now, since I seem to be the only person using this >> target, I think we should just remove it while I think again. >> (I can put it in my config.mak, so there will be no loss for me). > > As I said above, I would rather keep it, with the `ls-files` and `:=` > fixup. I would be happy with that, if you are. :-D ATB, Ramsay Jones

Re: [PATCH v2 1/1] Makefile: use `git ls-files` to list header files, if possible

2019-03-04 Thread Ramsay Jones
#x27;command-list.h' header is _sometimes_ not included in the LIB_H variable - it simply depends on whether it has been generated by the time the $(FIND) is called. Obviously, not worth a re-roll. Otherwise, this LGTM. Thanks! ATB, Ramsay Jones > easily worked around. Of the three si

Re: [PATCH v2 1/1] Makefile: use `git ls-files` to list header files, if possible

2019-03-04 Thread Ramsay Jones
On 04/03/2019 20:38, Ramsay Jones wrote: > > > On 04/03/2019 13:47, Johannes Schindelin via GitGitGadget wrote: >> From: Johannes Schindelin >> >> In d85b0dff72 (Makefile: use `find` to determine static header >> dependencies, 2014-08-25), we switched from a

[PATCH] Makefile: fix 'hdr-check' when GCRYPT not installed

2019-03-05 Thread Ramsay Jones
with 'xdiff/%' (and similarly for the compat pattern) since the original pattern inadvertently excluded the 'xdiff-interface.h' header. Signed-off-by: Ramsay Jones --- Hi Junio, In my local 'hdr-check-fixup' branch, the gcrypt failure is fixed almost by default. How

Re: [PATCH 1/1] Makefile: use `git ls-files` to list header files, if possible

2019-03-05 Thread Ramsay Jones
ts ... I deleted that email (it's not in my drafts folder anyway) because, in the end, it is not up to me to say how people should spend their time. So I won't! :-D ATB, Ramsay Jones

<    1   2   3   4   5   6   7   8   9   10   >