aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Mason <chris.mason@fusionio.com>2012-10-17 15:45:49 -0400
committerChris Mason <chris.mason@fusionio.com>2012-10-17 15:45:49 -0400
commit68d25bc003876ec2a681f8220d8e6f8be259f6cd (patch)
tree55478f935b0fed6000f9b24fc6e169f24630c04b
parent463b480f1a57cb0dfa523628b1af4033d8763332 (diff)
downloadiowatcher-68d25bc003876ec2a681f8220d8e6f8be259f6cd.tar.gz
Fix path name handling when the trace files are in the current directory
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
-rw-r--r--blkparse.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/blkparse.c b/blkparse.c
index f432f4d..7d32f40 100644
--- a/blkparse.c
+++ b/blkparse.c
@@ -633,7 +633,7 @@ static char *find_trace_file(char *filename)
try = strdup(filename);
dot = strrchr(try, '.');
if (!dot || strcmp(".dump", dot) != 0) {
- if (dot)
+ if (dot && dot != try)
*dot = '\0';
snprintf(line, 1024, "%s%s", try, ".blktrace.0");
ret = stat(line, &st);