summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2015-11-03Merge branch 'jc/mailinfo-lib'Libravatar Junio C Hamano1-1/+1
Hotfix for a topic already in 'master'. * jc/mailinfo-lib: mailinfo: fix passing wrong address to git_mailinfo_config
2015-11-03Merge branch 'kn/for-each-branch'Libravatar Junio C Hamano2-2/+2
Using the timestamp based criteria in "git branch --sort" did not tiebreak branches that point at commits with the same timestamp (or the same commit), making the resulting output unstable. * kn/for-each-branch: ref-filter: fallback on alphabetical comparison
2015-11-01mailinfo: fix passing wrong address to git_mailinfo_configLibravatar Nguyễn Thái Ngọc Duy1-1/+1
git_mailinfo_config() expects "struct mailinfo *". But in setup_mailinfo(), "mi" is already "struct mailinfo *". &mi would make it "struct mailinfo **" and git_mailinfo_config() would damage some other memory when it assigns some value to mi->use_scissors. This is caught by t4150.20. git_mailinfo_config() breaks mi->name.alloc and makes strbuf_release() in clear_mailinfo() attempt to free strbuf_slopbuf. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-30ref-filter: fallback on alphabetical comparisonLibravatar Karthik Nayak2-2/+2
In ref-filter.c the comparison of refs while sorting is handled by cmp_ref_sorting() function. When sorting as per numerical values (e.g. --sort=objectsize) there is no fallback comparison when both refs hold the same value. This can cause unexpected results (i.e. the order of listing refs with equal values cannot be pre-determined) as pointed out by Johannes Sixt ($gmane/280117). Hence, fallback to alphabetical comparison based on the refname whenever the other criterion is equal. A test in t3203 was expecting that branch-two sorts before HEAD, which happened to be how qsort(3) on Linux sorted the array, but (1) that outcome was not even guaranteed, and (2) once we start breaking ties with the refname, "HEAD" should sort before "branch-two" so the original expectation was inconsistent with the criterion we now use. Update it to match the new world order, which we can now depend on being stable. Helped-by: Junio C Hamano <gitster@pobox.com> Reported-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Karthik Nayak <Karthik.188@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-30Ninth batch for 2.7Libravatar Junio C Hamano1-2/+31
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-30Merge branch 'jk/merge-file-exit-code'Libravatar Junio C Hamano3-1/+38
"git merge-file" tried to signal how many conflicts it found, which obviously would not work well when there are too many of them. * jk/merge-file-exit-code: merge-file: clamp exit code to maximum 127
2015-10-30Merge branch 'gr/rebase-i-drop-warn'Libravatar Junio C Hamano2-0/+24
Recent update to "rebase -i" that tries to sanity check the edited insn sheet before it uses it has become too picky on Windows where CRLF left by the editor is turned into a trailing CR on the line read via the "read" built-in command. * gr/rebase-i-drop-warn: rebase-i: work around Windows CRLF line endings t3404: "rebase -i" gets broken when insn sheet uses CR/LF line endings
2015-10-30Merge branch 'xf/user-manual-ff'Libravatar Junio C Hamano1-5/+5
* xf/user-manual-ff: user-manual: fix the description of fast-forward
2015-10-30Merge branch 'rs/pop-commit'Libravatar Junio C Hamano10-92/+31
Code simplification. * rs/pop-commit: use pop_commit() for consuming the first entry of a struct commit_list
2015-10-30Merge branch 'mk/blame-error-message'Libravatar Junio C Hamano1-1/+1
The error message from "git blame --contents --reverse" incorrectly talked about "--contents --children". * mk/blame-error-message: blame: fix option name in error message
2015-10-30Merge branch 'js/misc-fixes'Libravatar Junio C Hamano5-6/+12
Various compilation fixes and squelching of warnings. * js/misc-fixes: Correct fscanf formatting string for I64u values Silence GCC's "cast of pointer to integer of a different size" warning Squelch warning about an integer overflow
2015-10-30Merge branch 'js/imap-send-curl-compilation-fix'Libravatar Junio C Hamano1-0/+4
"git imap-send" did not compile well with older version of cURL library. * js/imap-send-curl-compilation-fix: imap-send: only use CURLOPT_LOGIN_OPTIONS if it is actually available
2015-10-30Merge branch 'jk/delete-modechange-conflict'Libravatar Junio C Hamano5-89/+144
Merging a branch that removes a path and another that changes the mode bits on the same path should have conflicted at the path, but it didn't and silently favoured the removal. * jk/delete-modechange-conflict: merge: detect delete/modechange conflict t6031: generalize for recursive and resolve strategies t6031: move triple-rename test to t3030
2015-10-30Merge branch 'jc/add-u-A-default-to-top'Libravatar Junio C Hamano3-7/+4
"git --literal-pathspecs add -u/-A" without any command line argument misbehaved ever since Git 2.0. * jc/add-u-A-default-to-top: add: simplify -u/-A without pathspec
2015-10-30Merge branch 'ar/clone-dissociate'Libravatar Junio C Hamano3-10/+26
"git clone --dissociate" used to require that "--reference" was used at the same time, but you can create a new repository that borrows objects from another without using "--reference", namely with "clone --local" from a repository that borrows objects from other repositories. * ar/clone-dissociate: clone: allow "--dissociate" without reference
2015-10-30Merge git://ozlabs.org/~paulus/gitkLibravatar Junio C Hamano13-531/+450
* git://ozlabs.org/~paulus/gitk: gitk: Update Russian translation gitk: Add accelerator to German locale gitk: Add accelerators to Japanese locale gitk: Update msgid's for menu items with accelerator gitk: l10n: Update Catalan translation gitk: Add missing accelerators Updated Vietnamese translation
2015-10-30Merge https://github.com/vnwildman/gitkLibravatar Paul Mackerras1-22/+23
This brings in an update to the Vietnamese translation. Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-30gitk: Update Russian translationLibravatar Dimitriy Ryazantcev1-239/+160
Signed-off-by: Dimitriy Ryazantcev <dimitriy.ryazantcev@gmail.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-30gitk: Add accelerator to German localeLibravatar Takashi Iwai1-18/+18
Assigned either to the first letter or some unique letter. At least there are no conflicts, as far as I see... Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-30gitk: Add accelerators to Japanese localeLibravatar Takashi Iwai1-17/+17
Just follow the English accelerator keys. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-30gitk: Update msgid's for menu items with acceleratorLibravatar Takashi Iwai12-205/+205
The commit d99b4b0de27a ("gitk: Accelerators for the main menu") modified the menu item strings with the accelerator, but the translations didn't follow, thus the menus are shown without translations. This patch systematically update the msgid keys just to follow this change. The contents aren't changed, so the accelerator won't work in these locales for now. Each locale translator needs to add proper acceleration keys appropriately. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-30gitk: l10n: Update Catalan translationLibravatar Alex Henrie1-28/+25
The gitk included in git 2.6.0 crashes if run from a Catalan locale. I'm hoping that a translation update will fix this. Signed-off-by: Alex Henrie <alexhenrie24@gmail.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-30gitk: Add missing acceleratorsLibravatar Beat Bolli1-2/+2
In d99b4b0de27a ("gitk: Accelerators for the main menu", 2015-09-09), accelerators were added to allow efficient keyboard navigation. One instance of the strings "Edit view..." and "Delete view" were left without the ampersand. Add the missing ampersand characters to unbreak our international users. Signed-off-by: Beat Bolli <dev+git@drbeat.li> Signed-off-by: Paul Mackerras <paulus@samba.org>
2015-10-29Eighth batch for 2.7Libravatar Junio C Hamano1-1/+24
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-29Merge branch 'jc/am-mailinfo-direct'Libravatar Junio C Hamano1-19/+23
"git am" used to spawn "git mailinfo" via run_command() API once per each patch, but learned to make a direct call to mailinfo() instead. * jc/am-mailinfo-direct: am: make direct call to mailinfo
2015-10-29Merge branch 'jc/mailinfo-lib'Libravatar Junio C Hamano4-1035/+1099
The implementation of "git mailinfo" was refactored so that a mailinfo() function can be directly called from inside a process. * jc/mailinfo-lib: (34 commits) mailinfo: remove calls to exit() and die() deep in the callchain mailinfo: handle charset conversion errors in the caller mailinfo: libify mailinfo: keep the parsed log message in a strbuf mailinfo: handle_commit_msg() shouldn't be called after finding patchbreak mailinfo: move content/content_top to struct mailinfo mailinfo: move [ps]_hdr_data to struct mailinfo mailinfo: move cmitmsg and patchfile to struct mailinfo mailinfo: move charset to struct mailinfo mailinfo: move transfer_encoding to struct mailinfo mailinfo: move check for metainfo_charset to convert_to_utf8() mailinfo: move metainfo_charset to struct mailinfo mailinfo: move use_scissors and use_inbody_headers to struct mailinfo mailinfo: move add_message_id and message_id to struct mailinfo mailinfo: move patch_lines to struct mailinfo mailinfo: move filter/header stage to struct mailinfo mailinfo: move global "FILE *fin, *fout" to struct mailinfo mailinfo: move keep_subject & keep_non_patch_bracket to struct mailinfo mailinfo: introduce "struct mailinfo" to hold globals mailinfo: move global "line" into mailinfo() function ...
2015-10-29Merge branch 'rp/link-curl-before-ssl'Libravatar Junio C Hamano2-6/+34
The linkage order of libraries was wrong in places around libcurl. * rp/link-curl-before-ssl: configure.ac: detect ssl need with libcurl Makefile: make curl-config path configurable Makefile: link libcurl before zlib
2015-10-29Merge branch 'dt/name-hash-dir-entry-fix'Libravatar Junio C Hamano4-60/+35
The name-hash subsystem that is used to cope with case insensitive filesystems keeps track of directories and their on-filesystem cases for all the paths in the index by holding a pointer to a randomly chosen cache entry that is inside the directory (for its ce->ce_name component). This pointer was not updated even when the cache entry was removed from the index, leading to use after free. This was fixed by recording the path for each directory instead of borrowing cache entries and restructuring the API somewhat. * dt/name-hash-dir-entry-fix: name-hash: don't reuse cache_entry in dir_entry
2015-10-29Merge branch 'tk/sigchain-unnecessary-post-tempfile'Libravatar Junio C Hamano4-4/+0
Remove no-longer used #include. * tk/sigchain-unnecessary-post-tempfile: shallow: remove unused #include "sigchain.h" read-cache: remove unused #include "sigchain.h" diff: remove unused #include "sigchain.h" credential-cache--daemon: remove unused #include "sigchain.h"
2015-10-29Merge branch 'jk/war-on-sprintf'Libravatar Junio C Hamano2-1/+2
* jk/war-on-sprintf: compat/mingw.c: remove printf format warning read_branches_file: plug a FILE* leak
2015-10-29Merge branch 'jc/em-dash-in-doc'Libravatar Junio C Hamano6-6/+6
AsciiDoc markup fixes. * jc/em-dash-in-doc: Documentation: AsciiDoc spells em-dash as double-dashes, not triple
2015-10-29Merge branch 'jc/everyday-markup'Libravatar Junio C Hamano1-1/+1
AsciiDoc markup fixes. * jc/everyday-markup: Documentation/everyday: match undefline with the text
2015-10-29Merge branch 'xf/user-manual-markup'Libravatar Junio C Hamano11-11/+11
AsciiDoc markup fixes. * xf/user-manual-markup: Documentation: match undefline with the text in old release notes Documentation: match underline with the text Documentation: fix header markup
2015-10-29merge-file: clamp exit code to maximum 127Libravatar Jeff King3-1/+38
Git-merge-file is documented to return one of three exit codes: - zero means the merge was successful - a negative number means an error occurred - a positive number indicates the number of conflicts Unfortunately, this all gets stuffed into an 8-bit return code. Which means that if you have 256 conflicts, this wraps to zero, and the merge appears to succeed (and commits a blob full of conflict-marker cruft!). This patch clamps the return value to a maximum of 127, which we should be able to safely represent everywhere. This also leaves 128-255 for other values. Shells (and some parts of git) will typically represent signal death as 128 plus the signal number. And negative values are typically coerced to an 8-bit unsigned value (so "return -1" ends up as 255). Technically negative returns have the same problem (e.g., "-256" wraps back to 0), but this is not a problem in practice, as the only negative value we use is "-1". Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-28rebase-i: work around Windows CRLF line endingsLibravatar Junio C Hamano2-1/+13
Editors on Windows can and do save text files with CRLF line endings, which is the convention on the platform. We are seeing reports that the "read" command in a port of bash to the environment however does not strip the CRLF at the end, not adjusting for the same convention on the platform. This breaks the recently added sanity checks for the insn sheet fed to "rebase -i"; instead of an empty line (hence nothing in $command), the script was getting a lone CR in there. Special case a lone CR and treat it the same way as an empty line to work this around. This patch (also) passes the test with Git for Windows, where the issue was seen first. Signed-off-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-28t3404: "rebase -i" gets broken when insn sheet uses CR/LF line endingsLibravatar Johannes Schindelin1-0/+12
Based on a bug report by Chad Boles. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-26Seventh batch for 2.7Libravatar Junio C Hamano1-1/+36
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-26Merge branch 'dk/p4-import-ctypes'Libravatar Junio C Hamano1-0/+1
"git-p4" tried to use from ctypes module without first importing it. * dk/p4-import-ctypes: git-p4: import the ctypes module
2015-10-26Merge branch 'jk/repository-extension'Libravatar Junio C Hamano8-12/+209
Prepare for Git on-disk repository representation to undergo backward incompatible changes by introducing a new repository format version "1", with an extension mechanism. * jk/repository-extension: introduce "preciousObjects" repository extension introduce "extensions" form of core.repositoryformatversion
2015-10-26Merge branch 'dt/t7063-fix-flaky-test'Libravatar Junio C Hamano1-1/+3
* dt/t7063-fix-flaky-test: t7063: fix flaky untracked-cache test
2015-10-26Merge branch 'kn/for-each-tag'Libravatar Junio C Hamano1-0/+1
Recent update to "git tag --contains" caused a performance regression. * kn/for-each-tag: tag.c: use the correct algorithm for the '--contains' option
2015-10-26Merge branch 'es/worktree-add'Libravatar Junio C Hamano1-1/+1
* es/worktree-add: worktree: usage: denote <branch> as optional with 'add'
2015-10-26Merge branch 'tk/stripspace'Libravatar Junio C Hamano9-103/+118
The internal stripspace() function has been moved to where it logically belongs to, i.e. strbuf API, and the command line parser of "git stripspace" has been updated to use the parse_options API. * tk/stripspace: stripspace: use parse-options for command-line parsing strbuf: make stripspace() part of strbuf
2015-10-26Merge branch 'rt/placeholder-in-usage'Libravatar Junio C Hamano2-3/+3
A couple of commands still showed "[options]" in their usage string to note where options should come on their command line, but we spell that "[<options>]" in most places these days. * rt/placeholder-in-usage: am, credential-cache: add angle brackets to usage string
2015-10-26Merge branch 'jc/usage-stdin'Libravatar Junio C Hamano25-41/+64
The synopsis text and the usage string of subcommands that read list of things from the standard input are often shown as if they only take input from a file on a filesystem, which was misleading. * jc/usage-stdin: usage: do not insist that standard input must come from a file
2015-10-26Merge branch 'mr/worktree-list'Libravatar Junio C Hamano9-88/+485
Add the "list" subcommand to "git worktree". * mr/worktree-list: worktree: add 'list' command worktree: add details to the worktree struct worktree: add a function to get worktree details worktree: refactor find_linked_symref function worktree: add top-level worktree.c
2015-10-26Merge branch 'jc/am-3-fallback-regression-fix'Libravatar Junio C Hamano1-16/+33
"git am -3" had a small regression where it is aborted in its error handling codepath when underlying merge-recursive failed in certain ways, as it assumed that the internal call to merge-recursive will never die, which is not the case (yet). * jc/am-3-fallback-regression-fix: am -3: do not let failed merge from completing the error codepath
2015-10-26merge: detect delete/modechange conflictLibravatar Jeff King3-2/+37
If one side deletes a file and the other changes its content, we notice and report a conflict. However, if instead of changing the content, we change only the mode, the merge does not notice (and the mode change is silently dropped). The trivial index merge notices the problem and correctly leaves the conflict in the index, but both merge-recursive and merge-one-file will silently resolve this in favor of the deletion. In many cases that is a sane resolution, but we should be punting to the user whenever there is any question. So let's detect and treat this as a conflict (in both strategies). Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-26t6031: generalize for recursive and resolve strategiesLibravatar Jeff King2-56/+77
This script tests the filemode handling of merge-recursive, but we do not test the same thing for merge-resolve. Let's generalize the script a little: 1. Break out the setup steps for each test into a separate snippet. 2. For each test, run it twice; once with "-s recursive" and once with "-s resolve". We can avoid repeating ourselves by adding a function. 3. Since we have a nice abstracted function, we can make our tests more thorough by testing both directions (change on "ours" versus "theirs"). This improves our test coverage, and will make this the place to add more tests related to merging mode changes. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-26t6031: move triple-rename test to t3030Libravatar Jeff King2-31/+30
The t6031 test was introduced to check filemode handling of merge-recursive. Much later, an unrelated test was tacked on to look at renames and d/f conflicts. This test does not depend on anything that happened before (it actually blows away any existing content in the test repo). Let's move it to t3030, where there are more related tests. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>