Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make make(1): prepare str.c for WARNS=6
details: https://anonhg.NetBSD.org/src/rev/b2589ff865dc
branches: trunk
changeset: 943016:b2589ff865dc
user: rillig <rillig%NetBSD.org@localhost>
date: Sun Aug 23 18:03:35 2020 +0000
description:
make(1): prepare str.c for WARNS=6
The next step is to make brk_string return size_t instead of int.
diffstat:
usr.bin/make/str.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diffs (47 lines):
diff -r 1b4232f89cef -r b2589ff865dc usr.bin/make/str.c
--- a/usr.bin/make/str.c Sun Aug 23 17:51:24 2020 +0000
+++ b/usr.bin/make/str.c Sun Aug 23 18:03:35 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: str.c,v 1.60 2020/08/11 18:41:46 rillig Exp $ */
+/* $NetBSD: str.c,v 1.61 2020/08/23 18:03:35 rillig Exp $ */
/*-
* Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: str.c,v 1.60 2020/08/11 18:41:46 rillig Exp $";
+static char rcsid[] = "$NetBSD: str.c,v 1.61 2020/08/23 18:03:35 rillig Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)str.c 5.8 (Berkeley) 6/1/90";
#else
-__RCSID("$NetBSD: str.c,v 1.60 2020/08/11 18:41:46 rillig Exp $");
+__RCSID("$NetBSD: str.c,v 1.61 2020/08/23 18:03:35 rillig Exp $");
#endif
#endif /* not lint */
#endif
@@ -147,9 +147,9 @@
{
size_t str_len;
char *words_buf;
- int words_cap;
+ size_t words_cap;
char **words;
- int words_len;
+ size_t words_len;
char inquote;
char *word_start;
char *word_end;
@@ -282,7 +282,7 @@
}
done:
words[words_len] = NULL;
- *out_words_len = words_len;
+ *out_words_len = (int)words_len;
*out_words_buf = words_buf;
return words;
}
Home |
Main Index |
Thread Index |
Old Index