[RFC PATCH] lmdb: restrict the visibility of some symbols

2016-02-22 Thread Ramsay Jones
Signed-off-by: Ramsay Jones --- Hi David, If you need to re-roll your 'dt/refs-backend-lmdb' branch, please consider squashing something like this into the relevant patches. Note that I marked this as RFC, because I haven't got lmdb installed, so I can't actually

Re: [PATCH] tests: remove unused full-svn-test target

2016-02-22 Thread Kazutoshi Satoda
On 2016/02/22 12:08 +0900, Eric Wong wrote: > git-svn has not supported GIT_SVN_NO_OPTIMIZE_COMMITS for > the "set-tree" sub-command in 9 years since commit 490f49ea5899 > ("git-svn: remove optimized commit stuff for set-tree"). > > So remove this target to avoid confusion. > diff --git

Re: [PATCH +warn] Implement https public key pinning

2016-02-22 Thread Christoph Egger
Hi! Junio C Hamano writes: > Christoph Egger writes: > >> Add the http.pinnedpubkey configuration option for public key >> pinning. It allows any string supported by libcurl -- >> base64(sha256(pubkey)) or filename of the full public key. >> >>

[PATCH] completion: fix mis-indentation in _git_stash()

2016-02-22 Thread SZEDER Gábor
Signed-off-by: SZEDER Gábor --- contrib/completion/git-completion.bash | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash index 45ec47f2b1b4..e3918c87e3ad 100644 ---

Re: [PATCH 3/3] Correct conditions to free textconv result data

2016-02-22 Thread Duy Nguyen
On Mon, Feb 22, 2016 at 7:52 PM, Nguyễn Thái Ngọc Duy wrote: > fill_textconv() have four code paths to return a new buffer. I forgot to add. Thanks to -Wwrite-strings pointing to '*outbuf = ""' line in this function. I wouldn't notice otherwise. -- Duy -- To unsubscribe from

[PATCH 3/3] Correct conditions to free textconv result data

2016-02-22 Thread Nguyễn Thái Ngọc Duy
fill_textconv() have four code paths to return a new buffer. Two of them, run_textconv() and notes_cache_get(), return a newly allocated buffer. The other two return either a constant string or an existing buffer (mmfile_t). We can only free the result buffer if it's allocated by fill_textconv().

[PATCH 2/3] diff.c: remove unnecessary typecast

2016-02-22 Thread Nguyễn Thái Ngọc Duy
Signed-off-by: Nguyễn Thái Ngọc Duy --- diff.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/diff.c b/diff.c index 8b3a3db..5bdc3c0 100644 --- a/diff.c +++ b/diff.c @@ -717,8 +717,8 @@ static void emit_rewrite_diff(const char *name_a,

Re: GSoC 2016: Microproject

2016-02-22 Thread Mehul Jain
On Mon, Feb 22, 2016 at 4:51 PM, Duy Nguyen wrote: > OK server is up but very likely misconfigured. If you have experience > with http server before (I think this is apache), then you can dig in > t/lib-httpd.sh, study how the server is configured and try to fix it. Thanks

Question about pull-requests

2016-02-22 Thread Nagaraj Mandya
Hello, In our GIT repository, all users are restricted from merging to master without a pull request. This works well and all developers are raising pull requests and merging. However, if there is a merge conflict during the merge, we have a problem. We follow the instructions provided by

[PATCH v6 02/15] branch: report errors in tracking branch setup

2016-02-22 Thread Patrick Steinhardt
When setting up a new tracking branch fails due to issues with the configuration file we do not report any errors to the user and pretend setting the tracking branch succeeded. Setting up the tracking branch is handled by the `install_branch_config` function. We do not want to simply die there as

[PATCH v6 15/15] config: rename git_config_set_or_die to git_config_set

2016-02-22 Thread Patrick Steinhardt
Rename git_config_set_or_die functions to git_config_set, leading to the new default behavior of dying whenever a configuration error occurs. By now all callers that shall die on error have been transitioned to the _or_die variants, thus making this patch a simple rename of the functions.

[PATCH v6 04/15] branch: die on config error when editing branch description

2016-02-22 Thread Patrick Steinhardt
Signed-off-by: Patrick Steinhardt --- builtin/branch.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/builtin/branch.c b/builtin/branch.c index 0978287..c043cfc 100644 --- a/builtin/branch.c +++ b/builtin/branch.c @@ -570,7 +570,6 @@ static const char

[PATCH v6 03/15] branch: die on config error when unsetting upstream

2016-02-22 Thread Patrick Steinhardt
When we try to unset upstream configurations we do not check return codes for the `git_config_set` functions. As those may indicate that we were unable to unset the respective configuration we may exit successfully without any error message while in fact the upstream configuration was not unset.

[PATCH v6 14/15] config: rename git_config_set to git_config_set_gently

2016-02-22 Thread Patrick Steinhardt
The desired default behavior for `git_config_set` is to die whenever an error occurs. Dying is the default for a lot of internal functions when failures occur and is in this case the right thing to do for most callers as otherwise we might run into inconsistent repositories without noticing. As

[PATCH v6 11/15] init-db: die on config errors when initializing empty repo

2016-02-22 Thread Patrick Steinhardt
When creating an empty repository with `git init-db` we do not check for error codes returned by `git_config_set` functions. This may cause the user to end up with an inconsistent repository without any indication for the user. Fix this problem by dying early with an error message when we are

[PATCH v6 07/15] remote: die on config error when setting URL

2016-02-22 Thread Patrick Steinhardt
When invoking `git-remote --set-url` we do not check the return value when writing the actual new URL to the configuration file, pretending to the user that the configuration has been set while it was in fact not persisted. Fix this problem by dying early when setting the config fails.

[PATCH v6 13/15] compat: die when unable to set core.precomposeunicode

2016-02-22 Thread Patrick Steinhardt
When calling `git_config_set` to set 'core.precomposeunicode' we ignore the return value of the function, which may indicate that we were unable to write the value back to disk. As the function is only called by init-db we can and should die when an error occurs. Signed-off-by: Patrick Steinhardt

[PATCH v6 10/15] clone: die on config error in cmd_clone

2016-02-22 Thread Patrick Steinhardt
The clone command does not check for error codes returned by `git_config_set` functions. This may cause the user to end up with an inconsistent repository without any indication with what went wrong. Fix this problem by dying with an error message when we are unable to write the configuration

[PATCH v6 12/15] sequencer: die on config error when saving replay opts

2016-02-22 Thread Patrick Steinhardt
When we start picking a range of revisions we save the replay options that are required to restore state when interrupting and later continuing picking the revisions. However, we do not check the return values of the `git_config_set` functions, which may lead us to store incomplete information. As

[PATCH v6 09/15] remote: die on config error when manipulating remotes

2016-02-22 Thread Patrick Steinhardt
When manipulating remotes we try to set various configuration values without checking if the values were persisted correctly, possibly leaving the remote in an inconsistent state. Fix this issue by dying early and notifying the user about the error. Signed-off-by: Patrick Steinhardt

[PATCH v6 06/15] submodule--helper: die on config error when cloning module

2016-02-22 Thread Patrick Steinhardt
When setting the 'core.worktree' option for a newly cloned submodule we ignore the return value of `git_config_set_in_file`. As this leaves the submodule in an inconsistent state, we instead want to inform the user that something has gone wrong by printing an error and aborting the program.

[PATCH v6 08/15] remote: die on config error when setting/adding branches

2016-02-22 Thread Patrick Steinhardt
When we add or set new branches (e.g. by `git remote add -f` or `git remote set-branches`) we do not check for error codes when writing the branches to the configuration file. When persisting the configuration failed we are left with a remote that has none or not all of the branches that should

[PATCH v6 01/15] config: introduce set_or_die wrappers

2016-02-22 Thread Patrick Steinhardt
A lot of call-sites for the existing family of `git_config_set` functions do not check for errors that may occur, e.g. when the configuration file is locked. In many cases we simply want to die when such a situation arises. Introduce wrappers that will cause the program to die in those cases.

[PATCH v6 05/15] submodule: die on config error when linking modules

2016-02-22 Thread Patrick Steinhardt
When trying to connect a submodule with its corresponding repository in '.git/modules' we try to set the core.worktree setting in the submodule, which may fail due to an error encountered in `git_config_set_in_file`. The function is used in the git-mv command when trying to move a submodule to

[PATCH v6 00/15] config: make git_config_set die on failure

2016-02-22 Thread Patrick Steinhardt
Next revision of my patch series to improve error handling on git_config_set. Only three small changes to v5 [1], thanks for pointing these out: - fixed missing conversion of git_config_set_or_die in compat/precompose_utf8.c - fixed indentation in install_branch_config -

Re: GSoC 2016: Microproject

2016-02-22 Thread Duy Nguyen
On Mon, Feb 22, 2016 at 5:30 PM, Mehul Jain wrote: > On Mon, Feb 22, 2016 at 3:50 PM, Duy Nguyen wrote: >> You may have an http server installed but not suitable for these >> tests. Try running one test file alone with -v -i, e.g. >>

Re: [PATCH] tests: rename work-tree tests to *work-tree*

2016-02-22 Thread Michael J Gruber
Junio C Hamano venit, vidit, dixit 20.02.2016 22:42: > Michael J Gruber writes: > >> "Work tree" or "working tree" is the name of a checked out tree, >> "worktree" the name of the command which manages several working trees. >> The naming of tests mixes these two,

Re: GSoC 2016: Microproject

2016-02-22 Thread Lars Schneider
> On 22 Feb 2016, at 11:21, Lars Schneider wrote: > > >> On 22 Feb 2016, at 11:12, Mehul Jain wrote: >> >> On Mon, Feb 22, 2016 at 12:22 AM, Matthieu Moy >> wrote: >>> The simplest way to get back on track for

Re: GSoC 2016: Microproject

2016-02-22 Thread Lars Schneider
> On 22 Feb 2016, at 11:12, Mehul Jain wrote: > > On Mon, Feb 22, 2016 at 12:22 AM, Matthieu Moy > wrote: >> The simplest way to get back on track for you is probably to start over >> with a fresh clone, or (warning: destructive

Re: GSoC 2016: Microproject

2016-02-22 Thread Mehul Jain
On Mon, Feb 22, 2016 at 3:50 PM, Duy Nguyen wrote: > You may have an http server installed but not suitable for these > tests. Try running one test file alone with -v -i, e.g. > ./t5539-fetch-http-shallow.sh -v -i and post the output. Here's the output :- expecting success:

Re: GSoC 2016: applications open, deadline = Fri, 19/2

2016-02-22 Thread Matthieu Moy
Duy Nguyen writes: > On Sat, Feb 13, 2016 at 6:21 PM, Matthieu Moy > wrote: >> Less urgent, but we need to add more stuff to be credible: >> >> ... >> >> http://git.github.io/SoC-2016-Microprojects/ => I just did s/2015/2016/. >> I think most

Re: GSoC 2016: Microproject

2016-02-22 Thread Duy Nguyen
On Mon, Feb 22, 2016 at 5:12 PM, Mehul Jain wrote: > On Mon, Feb 22, 2016 at 12:22 AM, Matthieu Moy > wrote: >> The simplest way to get back on track for you is probably to start over >> with a fresh clone, or (warning: destructive

Re: GSoC 2016: Microproject

2016-02-22 Thread Mehul Jain
On Mon, Feb 22, 2016 at 12:22 AM, Matthieu Moy wrote: > The simplest way to get back on track for you is probably to start over > with a fresh clone, or (warning: destructive operations): use git clean > to remove untracked files. Hello Matthieu, I followed your

Re: [PATCH] GSoC Micoproject: Hunt down signed int flags

2016-02-22 Thread Duy Nguyen
On Sun, Feb 21, 2016 at 6:13 PM, Saurav Sachidanand wrote: > This is patch is for a suggested micro project for GSoC 2016; namely, > that of searching for a field of a struct that is of signed integral > type and used as a collection of multiple bits, and converting

Re: GSoC 2016: applications open, deadline = Fri, 19/2

2016-02-22 Thread Duy Nguyen
On Sat, Feb 13, 2016 at 6:21 PM, Matthieu Moy wrote: > Less urgent, but we need to add more stuff to be credible: > > ... > > http://git.github.io/SoC-2016-Microprojects/ => I just did s/2015/2016/. > I think most projects are not valid anymore, and we need new ones.

[PATCH v7 1/2] fixup: config: add 'origin_type' to config_source struct

2016-02-22 Thread larsxschneider
From: Lars Schneider --- config.c | 4 ++-- t/t1300-repo-config.sh | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/config.c b/config.c index 3be2cbc..0fce371 100644 --- a/config.c +++ b/config.c @@ -1081,7 +1081,7 @@ static int

[PATCH v7 2/2] fixup: config: add '--show-origin' option to print the origin of a config value

2016-02-22 Thread larsxschneider
From: Lars Schneider --- Documentation/git-config.txt | 5 +++-- builtin/config.c | 2 +- t/t1300-repo-config.sh | 6 +++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/Documentation/git-config.txt b/Documentation/git-config.txt

[PATCH v6 squash 0/2] config: add '--sources' option to print the source of a config value

2016-02-22 Thread larsxschneider
From: Lars Schneider Hi Junio, please squash these two patches into the corresponding patches from my v6 to spell out end user facing messages (response to [1], sorry gmane didn't work for me). I am not sure about the right way an answer with a "two patch" squash on

Re: GSoC 2016: Microproject

2016-02-22 Thread Matthieu Moy
Please, don't top-post on this list. Mehul Jain writes: > Hello, > > I faced the following problem when I tested master branch. Here I have > made no commits to master branch. Are you sure that 1) you have no uncommitted change and 2) you have compiled what you have

Re: [PATCH 1/1] convert.c: correct attr_action

2016-02-22 Thread Junio C Hamano
tbo...@web.de writes: > diff --git a/convert.c b/convert.c > index 18af685..0bc32ec 100644 > --- a/convert.c > +++ b/convert.c > @@ -708,7 +708,7 @@ static enum crlf_action git_path_check_crlf(struct > git_attr_check *check) > const char *value = check->value; > > if

Re: GSoC 2016: Microproject

2016-02-22 Thread Karthik Nayak
On Mon, Feb 22, 2016 at 12:22 AM, Matthieu Moy wrote: > Mehul Jain writes: > >> Earlier when I was testing the master branch on my pc, I used "make" >> in \t directory, which lead to failure of test #2, #3 in >> t5539-fetch-http-shallow.sh

Re: [PATCH 1/1] convert.c: correct attr_action

2016-02-22 Thread Junio C Hamano
tbo...@web.de writes: > diff --git a/t/t0027-auto-crlf.sh b/t/t0027-auto-crlf.sh > index fc4c628..f9c92c6 100755 > --- a/t/t0027-auto-crlf.sh > +++ b/t/t0027-auto-crlf.sh > @@ -159,6 +159,39 @@ stats_ascii () { > > } > > +attr_ascii () { > + case "$1" in > + "-text") echo "-text"

<    1   2