* contrib/ari/gdb_ari.sh: Remove rules for xasprintf and
xvasprintf. * common/common-utils.c (xasprintf, xvasprintf): Remove. * common/common-utils.h (xasprintf, xvasprintf): Remove.
This commit is contained in:
parent
cdde3dfbda
commit
a93478eab4
4 changed files with 7 additions and 43 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2012-11-29 Tom Tromey <tromey@redhat.com>
|
||||||
|
|
||||||
|
* contrib/ari/gdb_ari.sh: Remove rules for xasprintf and
|
||||||
|
xvasprintf.
|
||||||
|
* common/common-utils.c (xasprintf, xvasprintf): Remove.
|
||||||
|
* common/common-utils.h (xasprintf, xvasprintf): Remove.
|
||||||
|
|
||||||
2012-11-29 Jerome Guitton <guitton@adacore.com>
|
2012-11-29 Jerome Guitton <guitton@adacore.com>
|
||||||
|
|
||||||
* ada-lang.c (ada_is_interface_tag): New function.
|
* ada-lang.c (ada_is_interface_tag): New function.
|
||||||
|
|
|
@ -137,22 +137,6 @@ xstrvprintf (const char *format, va_list ap)
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
xasprintf (char **ret, const char *format, ...)
|
|
||||||
{
|
|
||||||
va_list args;
|
|
||||||
|
|
||||||
va_start (args, format);
|
|
||||||
(*ret) = xstrvprintf (format, args);
|
|
||||||
va_end (args);
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
|
||||||
xvasprintf (char **ret, const char *format, va_list ap)
|
|
||||||
{
|
|
||||||
(*ret) = xstrvprintf (format, ap);
|
|
||||||
}
|
|
||||||
|
|
||||||
int
|
int
|
||||||
xsnprintf (char *str, size_t size, const char *format, ...)
|
xsnprintf (char *str, size_t size, const char *format, ...)
|
||||||
{
|
{
|
||||||
|
|
|
@ -43,13 +43,6 @@ char *xstrprintf (const char *format, ...) ATTRIBUTE_PRINTF (1, 2);
|
||||||
char *xstrvprintf (const char *format, va_list ap)
|
char *xstrvprintf (const char *format, va_list ap)
|
||||||
ATTRIBUTE_PRINTF (1, 0);
|
ATTRIBUTE_PRINTF (1, 0);
|
||||||
|
|
||||||
/* Like asprintf/vasprintf but get an internal_error if the call
|
|
||||||
fails. */
|
|
||||||
void xasprintf (char **ret, const char *format, ...)
|
|
||||||
ATTRIBUTE_PRINTF (2, 3);
|
|
||||||
void xvasprintf (char **ret, const char *format, va_list ap)
|
|
||||||
ATTRIBUTE_PRINTF (2, 0);
|
|
||||||
|
|
||||||
/* Like snprintf, but throw an error if the output buffer is too small. */
|
/* Like snprintf, but throw an error if the output buffer is too small. */
|
||||||
int xsnprintf (char *str, size_t size, const char *format, ...)
|
int xsnprintf (char *str, size_t size, const char *format, ...)
|
||||||
ATTRIBUTE_PRINTF (3, 4);
|
ATTRIBUTE_PRINTF (3, 4);
|
||||||
|
|
|
@ -1127,26 +1127,6 @@ Do not use vasprintf(), instead use xstrvprintf"
|
||||||
fail("vasprintf")
|
fail("vasprintf")
|
||||||
}
|
}
|
||||||
|
|
||||||
BEGIN { doc["xasprintf"] = "\
|
|
||||||
Do not use xasprintf(), instead use xstrprintf"
|
|
||||||
fix("xasprintf", "common/common-utils.h", 1)
|
|
||||||
fix("xasprintf", "common/common-utils.c", 1)
|
|
||||||
category["xasprintf"] = ari_regression
|
|
||||||
}
|
|
||||||
/(^|[^_[:alnum:]])xasprintf[[:space:]]*\(/ {
|
|
||||||
fail("xasprintf")
|
|
||||||
}
|
|
||||||
|
|
||||||
BEGIN { doc["xvasprintf"] = "\
|
|
||||||
Do not use xvasprintf(), instead use xstrvprintf"
|
|
||||||
fix("xvasprintf", "common/common-utils.h", 1)
|
|
||||||
fix("xvasprintf", "common/common-utils.c", 1)
|
|
||||||
category["xvasprintf"] = ari_regression
|
|
||||||
}
|
|
||||||
/(^|[^_[:alnum:]])xvasprintf[[:space:]]*\(/ {
|
|
||||||
fail("xvasprintf")
|
|
||||||
}
|
|
||||||
|
|
||||||
# More generic memory operations
|
# More generic memory operations
|
||||||
|
|
||||||
BEGIN { doc["bzero"] = "\
|
BEGIN { doc["bzero"] = "\
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue