aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetr Machata <pmachata@redhat.com>2012-12-05 01:22:54 +0100
committerPetr Machata <pmachata@redhat.com>2013-03-08 22:55:28 +0100
commit13c939cb455d4881701e2da1bd770de0b3afc788 (patch)
treeb1333f630d1a5d040c9881763dfaf72a82bffacb
parente7be390210e6be64d21fa0c4b71d6fcfc45f4dcf (diff)
downloadltrace-13c939cb455d4881701e2da1bd770de0b3afc788.tar.gz
read_config_file.c: In "unknown type" error, show the piece that caused it
-rw-r--r--read_config_file.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/read_config_file.c b/read_config_file.c
index 0b32ec9..91f05e7 100644
--- a/read_config_file.c
+++ b/read_config_file.c
@@ -872,6 +872,7 @@ parse_nonpointer_type(struct protolib *plib, struct locus *loc,
char **str, struct param **extra_param, size_t param_num,
int *ownp, int *forwardp)
{
+ const char *orig_str = *str;
enum arg_type type;
if (parse_arg_type(str, &type) < 0) {
struct arg_type_info *simple;
@@ -886,7 +887,7 @@ parse_nonpointer_type(struct protolib *plib, struct locus *loc,
}
report_error(loc->filename, loc->line_no,
- "unknown type around '%s'", *str);
+ "unknown type around '%s'", orig_str);
return NULL;
}