git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joey Hess <joey@kitenet.net>
To: git@vger.kernel.org
Subject: RLIMIT_NOFILE fallback
Date: Wed, 18 Dec 2013 13:14:46 -0400	[thread overview]
Message-ID: <20131218171446.GA19657@kitenet.net> (raw)

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

In sha1_file.c, when git is built on linux, it will use 
getrlimit(RLIMIT_NOFILE). I've been deploying git binaries to some
unusual systems, like embedded NAS devices, and it seems some with older
kernels like 2.6.33 fail with "fatal: cannot get RLIMIT_NOFILE: Bad address".

I could work around this by building git without RLIMIT_NOFILE defined,
but perhaps it would make sense to improve the code to fall back
to one of the other methods for getting the limit, and/or return the
hardcoded 1 as a fallback. This would make git binaries more robust
against old/broken/misconfigured kernels.

-- 
see shy jo

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

             reply	other threads:[~2013-12-18 17:14 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-18 17:14 Joey Hess [this message]
2013-12-18 18:00 ` RLIMIT_NOFILE fallback Junio C Hamano
2013-12-18 18:41   ` Joey Hess
2013-12-18 19:17   ` Jeff King
2013-12-18 19:50     ` Junio C Hamano
2013-12-18 20:18       ` Junio C Hamano
2013-12-18 21:28       ` Jeff King
2013-12-18 21:37         ` Junio C Hamano
2013-12-18 21:40           ` Jeff King
2013-12-18 22:59             ` Junio C Hamano
2013-12-19  0:15               ` Jeff King
2013-12-19 17:30                 ` Torsten Bögershausen
2013-12-19 17:39                   ` Junio C Hamano
2013-12-20  9:12                     ` Jeff King
2013-12-20 14:43                       ` Torsten Bögershausen
2013-12-18 20:03     ` Joey Hess

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=20131218171446.GA19657@kitenet.net \
    --to=joey@kitenet.net \
    --cc=git@vger.kernel.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).