[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: human interface change?!? [Re: xstrtol.h
From: |
Paul Eggert |
Subject: |
Re: human interface change?!? [Re: xstrtol.h |
Date: |
Thu, 09 Aug 2007 15:04:47 -0700 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) |
Jim Meyering <address@hidden> writes:
> find's locate.c uses it, too.
Thanks for mentioning that. Here's a patch for that, which I've
verified with 'make check' in findutils. It can be installed if the
proposed gnulib change is OK.
2007-08-09 Paul Eggert <address@hidden>
* locate/locate.c (dolocate): Adjust to API change of
xstrtol gnulib module.
Index: locate/locate.c
===================================================================
RCS file: /cvsroot/findutils/findutils/locate/locate.c,v
retrieving revision 1.89
diff -p -u -b -w -r1.89 locate.c
--- locate/locate.c 5 Aug 2007 12:22:14 -0000 1.89
+++ locate/locate.c 9 Aug 2007 22:02:36 -0000
@@ -1567,6 +1567,7 @@ dolocate (int argc, char **argv, int sec
char *dbpath;
unsigned long int found = 0uL;
int optc;
+ int opti;
int ignore_case = 0;
int print = 0;
int just_count = 0;
@@ -1608,7 +1609,7 @@ dolocate (int argc, char **argv, int sec
check_existence = ACCEPT_EITHER;
- while ((optc = getopt_long (argc, argv, "Abcd:eEil:prsm0SwHPL", longopts,
(int *) 0)) != -1)
+ while ((optc = getopt_long (argc, argv, "Abcd:eEil:prsm0SwHPL", longopts,
&opti)) != -1)
switch (optc)
{
case '0':
@@ -1698,7 +1699,7 @@ dolocate (int argc, char **argv, int sec
strtol_error err = xstrtoumax(optarg, &end, 10, &limits.limit, NULL);
if (LONGINT_OK != err)
{
- STRTOL_FATAL_ERROR(optarg, _("argument to --limit"), err);
+ xstrtol_fatal (err, opti, optc, longopts, optarg);
}
use_limit = 1;
}
Re: human interface change?!? [Re: xstrtol.h, Bruno Haible, 2007/08/04