git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Paul Umbers" <paul.umbers@gmail.com>
To: "Alex Riesen" <raa.lkml@gmail.com>
Cc: git@vger.kernel.org, "Junio C Hamano" <junkio@cox.net>,
	"Linus Torvalds" <torvalds@linux-foundation.org>
Subject: Re: Git Cygwin - unable to create any repository - help!
Date: Thu, 17 Jan 2008 11:37:37 -0700	[thread overview]
Message-ID: <a5eb9c330801171037v333becc2lbc5873383d07a358@mail.gmail.com> (raw)
In-Reply-To: <20080116234527.GA3499@steel.home>

[-- Attachment #1: Type: text/plain, Size: 2122 bytes --]

Made the changes you specify below & re-ran "make install". Attached
is the log from the latest strace.

Incidentally, I've tried this on two other machines at work with the
same results. The steps to reproduce are annoyingly simple: download
cygwin installer & execute (accept all defaults), select the packages
specified for the binary windows install on the git wiki, try to
create a git repository and add files. Frustrating - especially since
my desktop at my last job worked just fine.

Paul

On Jan 16, 2008 4:45 PM, Alex Riesen <raa.lkml@gmail.com> wrote:
SNIP
>
> Could you locate move_temp_to_file and make it unconditionally rename
> the tempfile into target sha1 file? It should become something like that:
>
> int move_temp_to_file(const char *tmpfile, const char *filename)
> {
>         int ret = link_temp_to_file(tmpfile, filename);
>
>         /*
>          * Coda hack - coda doesn't like cross-directory links,
>          * so we fall back to a rename, which will mean that it
>          * won't be able to check collisions, but that's not a
>          * big deal.
>          *
>          * The same holds for FAT formatted media.
>          *
>          * When this succeeds, we just return 0. We have nothing
>          * left to unlink.
>          */
>         if (!rename(tmpfile, filename))
>                 return 0;
>         ret = errno;
>         unlink(tmpfile);
>         if (ret) {
>                 if (ret != EEXIST) {
>                         return error("unable to write sha1 filename %s: %s\n", filename, strerror(ret));
>                 }
>                 /* FIXME!!! Collision check here ? */
>                 return error("failed to write sha1 filename %s: %s\n", filename, strerror(ret));
>         }
>
>         return 0;
> }
>
> Does someone know, why this function seem to return 0 (success) on
> something which looks like an SHA1 collision? And destroy the
> tempfile, even though it is not moved anywhere.
>
>



-- 
Computer Science is no more about computers than astronomy is about telescopes.
--- Edsger W. Dijkstra

Paul Umbers MSc MBCS MIAP
paul.umbers@gmail.com

[-- Attachment #2: log3.tar.gz --]
[-- Type: application/x-gzip, Size: 26705 bytes --]

  reply	other threads:[~2008-01-17 18:38 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-14 17:21 Git Cygwin - unable to create any repository - help! Paul Umbers
2008-01-14 20:29 ` Alex Riesen
2008-01-14 22:21   ` Paul Umbers
2008-01-15  5:48     ` Alex Riesen
2008-01-15 15:21       ` Paul Umbers
2008-01-15 20:04         ` Alex Riesen
2008-01-15 20:12           ` Paul Umbers
2008-01-15 21:20             ` Alex Riesen
2008-01-15 21:57               ` Paul Umbers
2008-01-15 22:51                 ` Alex Riesen
2008-01-15 21:59               ` Paul Umbers
2008-01-15 22:55                 ` Alex Riesen
2008-01-15 23:02             ` Robin Rosenberg
2008-01-16  7:18               ` Alex Riesen
2008-01-16 15:42                 ` Paul Umbers
2008-01-16 17:55                   ` Junio C Hamano
2008-01-16 18:10                     ` Paul Umbers
2008-01-16 18:38                       ` Alex Riesen
2008-01-16 18:57                         ` Paul Umbers
2008-01-16 18:31                   ` Alex Riesen
2008-01-16 18:48                     ` Paul Umbers
2008-01-16 19:12                       ` Alex Riesen
2008-01-16 19:17                       ` Alex Riesen
2008-01-16 21:44                         ` Paul Umbers
2008-01-16 23:45                           ` Alex Riesen
2008-01-17 18:37                             ` Paul Umbers [this message]
2008-01-17 18:51                               ` Linus Torvalds
2008-01-17 19:17                                 ` Johannes Schindelin
2008-01-17 20:13                                 ` Paul Umbers
2008-01-17 20:24                                   ` Linus Torvalds
2008-01-17 20:38                                     ` Pascal Obry
2008-01-17 20:50                                       ` Johannes Schindelin
2008-01-17 20:53                                         ` Pascal Obry
2008-01-17 22:32                                     ` Paul Umbers
2008-01-17 20:18                               ` Alex Riesen
2008-01-17 18:53                             ` Nicholas Wourms
2008-01-17 20:30                               ` Alex Riesen
2008-01-16 18:50                     ` Paul Umbers
2008-01-15 17:08     ` Pascal Obry

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a5eb9c330801171037v333becc2lbc5873383d07a358@mail.gmail.com \
    --to=paul.umbers@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    --cc=raa.lkml@gmail.com \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).