Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread tsuna
On Sun, Aug 24, 2014 at 5:32 PM, Ramsay Jones wrote: > Again, I don't have access to an OS X system, so I don't know > which package provides libintl/gettext, but it seems to be missing > on your system. Probably yeah, those libraries don’t seem to be provided in standard with OS X or OS X’s deve

Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread Ramsay Jones
On 24/08/14 22:09, tsuna wrote: > On Sun, Aug 24, 2014 at 12:49 PM, Torsten Bögershausen wrote: >> On 2014-08-24 18.18, Ramsay Jones wrote: >>> On 24/08/14 12:13, tsuna wrote: On Sun, Aug 24, 2014 at 4:10 AM, Ramsay Jones wrote: > Hmm, which version of OS X are we talking about? >>>

Re: [PATCH] bisect: save heap memory. allocate only the required amount

2014-08-24 Thread Junio C Hamano
On Sun, Aug 24, 2014 at 8:10 AM, Stefan Beller wrote: >> for (p = list, i = 0; i < cnt; i++) { >> - struct name_decoration *r = xmalloc(sizeof(*r) + 100); >> + char name[100]; > > Would it make sense to convert the 'name' into a git strbuf? > Please have a look at Doc

[PATCH] bisect: save heap memory. allocate only the required amount

2014-08-24 Thread Arjun Sreedharan
find and allocate the required amount instead of allocating extra 100 bytes Signed-off-by: Arjun Sreedharan --- bisect.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/bisect.c b/bisect.c index d6e851d..a52631e 100644 --- a/bisect.c +++ b/bisect.c @@ -215,12 +215,16

Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread tsuna
On Sun, Aug 24, 2014 at 12:49 PM, Torsten Bögershausen wrote: > On 2014-08-24 18.18, Ramsay Jones wrote: >> On 24/08/14 12:13, tsuna wrote: >>> On Sun, Aug 24, 2014 at 4:10 AM, Ramsay Jones >>> wrote: Hmm, which version of OS X are we talking about? >>> >>> OS X 10.9.4: >>> >>> $ uname -a >>

Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread Torsten Bögershausen
On 2014-08-24 18.18, Ramsay Jones wrote: > On 24/08/14 12:13, tsuna wrote: >> On Sun, Aug 24, 2014 at 4:10 AM, Ramsay Jones >> wrote: >>> Hmm, which version of OS X are we talking about? >> >> OS X 10.9.4: >> >> $ uname -a >> Darwin damogran.local 13.3.0 Darwin Kernel Version 13.3.0: Tue Jun 3 >>

Re: [PATCH 2/2] Loop index increases monotonically when reading unmerged entries

2014-08-24 Thread Jaime Soriano Pastor
I think this line is dangerous, if add_cache_entry is not able to remove higher-stages it will be looping forever, as happens in the case of this thread. I cannot see why it's even needed, and removing it doesn't break any test. On Sun, Aug 24, 2014 at 7:57 PM, Jaime Soriano Pastor wrote: > Signe

[PATCH 2/2] Loop index increases monotonically when reading unmerged entries

2014-08-24 Thread Jaime Soriano Pastor
Signed-off-by: Jaime Soriano Pastor --- read-cache.c | 1 - 1 file changed, 1 deletion(-) diff --git a/read-cache.c b/read-cache.c index c1a9619..3d70386 100644 --- a/read-cache.c +++ b/read-cache.c @@ -1971,7 +1971,6 @@ int read_index_unmerged(struct index_state *istate) if (add

[PATCH 1/2] Check order when reading index

2014-08-24 Thread Jaime Soriano Pastor
Signed-off-by: Jaime Soriano Pastor --- read-cache.c | 18 ++ 1 file changed, 18 insertions(+) diff --git a/read-cache.c b/read-cache.c index 7f5645e..c1a9619 100644 --- a/read-cache.c +++ b/read-cache.c @@ -1438,6 +1438,21 @@ static struct cache_entry *create_from_disk(struct o

Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread Ramsay Jones
On 24/08/14 12:13, tsuna wrote: > On Sun, Aug 24, 2014 at 4:10 AM, Ramsay Jones > wrote: >> Hmm, which version of OS X are we talking about? > > OS X 10.9.4: > > $ uname -a > Darwin damogran.local 13.3.0 Darwin Kernel Version 13.3.0: Tue Jun 3 > 21:27:35 PDT 2014; root:xnu-2422.110.17~1/RELEASE

[PATCH v5 3/4] Introduce GIT_MMAP_LIMIT to allow testing expected mmap size

2014-08-24 Thread Steffen Prohaska
Similar to testing expectations about malloc with GIT_ALLOC_LIMIT (see commit d41489 and previous commit), it can be useful to test expectations about mmap. This introduces a new environment variable GIT_MMAP_LIMIT to limit the largest allowed mmap length. xmmap() is modified to check the limit.

[PATCH v5 0/4] Stream fd to clean filter; GIT_MMAP_LIMIT, GIT_ALLOC_LIMIT with git_parse_ulong()

2014-08-24 Thread Steffen Prohaska
Changes since v4: use git_parse_ulong() to parse env vars. Steffen Prohaska (4): convert: Refactor would_convert_to_git() to single arg 'path' Change GIT_ALLOC_LIMIT check to use git_parse_ulong() Introduce GIT_MMAP_LIMIT to allow testing expected mmap size convert: Stream from fd to requi

[PATCH v5 2/4] Change GIT_ALLOC_LIMIT check to use git_parse_ulong()

2014-08-24 Thread Steffen Prohaska
GIT_ALLOC_LIMIT limits xmalloc()'s size, which is of type size_t. Better use git_parse_ulong() to parse the environment variable, so that the postfixes 'k', 'm', and 'g' can be used; and use size_t to store the limit for consistency. The change to size_t has no direct practical impact, because we

[PATCH v5 1/4] convert: Refactor would_convert_to_git() to single arg 'path'

2014-08-24 Thread Steffen Prohaska
It is only the path that matters in the decision whether to filter or not. Clarify this by making path the single argument of would_convert_to_git(). Signed-off-by: Steffen Prohaska --- convert.h | 5 ++--- sha1_file.c | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/con

[PATCH v5 4/4] convert: Stream from fd to required clean filter instead of mmap

2014-08-24 Thread Steffen Prohaska
The data is streamed to the filter process anyway. Better avoid mapping the file if possible. This is especially useful if a clean filter reduces the size, for example if it computes a sha1 for binary data, like git media. The file size that the previous implementation could handle was limited b

Re: [PATCH v3 2/3] Introduce GIT_MMAP_LIMIT to allow testing expected mmap size

2014-08-24 Thread Steffen Prohaska
On Aug 22, 2014, at 6:31 PM, Junio C Hamano wrote: > Steffen Prohaska writes: > + if (limit == -1) { + const char *env = getenv("GIT_MMAP_LIMIT"); + limit = env ? atoi(env) * 1024 : 0; >> >> ... this should then be changed to atol(env), and ... > > In the re

Re: [PATCH] bisect: save heap memory. allocate only the required amount

2014-08-24 Thread Ramsay Jones
On 24/08/14 15:17, Arjun Sreedharan wrote: > Find and allocate the required amount instead of > allocating extra 100 bytes > > Signed-off-by: Arjun Sreedharan > --- > bisect.c | 7 +-- > 1 file changed, 5 insertions(+), 2 deletions(-) > > diff --git a/bisect.c b/bisect.c > index d6e851d..c9

REPLY ASAP, IT'S URGENT.

2014-08-24 Thread Mr. Larry Markson
Attention: I have a business Proposal that will be of benefit to the both of us and I shall be compensating you with Forty percent at the final conclusion. If you are interested please reply ASAP, so I can send you more detail on how we are going to proceed I await your urgent response, Regar

Re: [PATCH] bisect: save heap memory. allocate only the required amount

2014-08-24 Thread Stefan Beller
On 24.08.2014 16:17, Arjun Sreedharan wrote: > Find and allocate the required amount instead of > allocating extra 100 bytes > > Signed-off-by: Arjun Sreedharan > --- > bisect.c | 7 +-- > 1 file changed, 5 insertions(+), 2 deletions(-) > > diff --git a/bisect.c b/bisect.c > index d6e851d..

[PATCH] bisect: save heap memory. allocate only the required amount

2014-08-24 Thread Arjun Sreedharan
Find and allocate the required amount instead of allocating extra 100 bytes Signed-off-by: Arjun Sreedharan --- bisect.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/bisect.c b/bisect.c index d6e851d..c96aab0 100644 --- a/bisect.c +++ b/bisect.c @@ -215,10 +215,13 @

Re: [PATCH 1/5] git-prompt: do not look for refs/stash in $GIT_DIR

2014-08-24 Thread Gábor Szeder
Hi, On Aug 23, 2014 12:26 PM, Jeff King wrote: > Since dd0b72c (bash prompt: use bash builtins to check stash > state, 2011-04-01), git-prompt checks whether we have a > stash by looking for $GIT_DIR/refs/stash. Generally external > programs should never do this, because they would miss > pac

Re: Re: Relative submodule URLs

2014-08-24 Thread Heiko Voigt
Hi, since the mail got quite long. To avoid 'tl;dr', I talk about two topics in this mail: * Submodule settings for default remote (complex, future) * New --with--remote parameter for 'git submodule' (simple, now) Depending on your interest you might want to skip the first part of the email.

Re: [PATCH 2/2] describe: Add documentation for "--abbrev=+"

2014-08-24 Thread Jonh Wendell
2014-08-24 3:35 GMT-03:00 brian m. carlson : > On Sat, Aug 23, 2014 at 02:13:22PM -0300, Jonh Wendell wrote: >> --- >> Documentation/git-describe.txt | 6 ++ >> 1 file changed, 6 insertions(+) >> >> diff --git a/Documentation/git-describe.txt b/Documentation/git-describe.txt >> index d20ca40..

Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread tsuna
On Sun, Aug 24, 2014 at 4:10 AM, Ramsay Jones wrote: > Hmm, which version of OS X are we talking about? OS X 10.9.4: $ uname -a Darwin damogran.local 13.3.0 Darwin Kernel Version 13.3.0: Tue Jun 3 21:27:35 PDT 2014; root:xnu-2422.110.17~1/RELEASE_X86_64 x86_64 > config.mak.uname contains this:

Re: [PATCH] Undefine strlcpy if needed.

2014-08-24 Thread Ramsay Jones
On 24/08/14 05:35, Benoit Sigoure wrote: > On OS X, strlcpy is already #define'd, which causes warnings > in all the files that include `git-compat-util.h'. Note that > this only occurs when building without running ./configure. > > Signed-off-by: Benoit Sigoure > --- > > Resending with the SOB