summaryrefslogtreecommitdiff
path: root/util/tracediff
diff options
context:
space:
mode:
authorSteve Reinhardt <Steve.Reinhardt@amd.com>2008-11-17 11:22:16 -0800
committerSteve Reinhardt <Steve.Reinhardt@amd.com>2008-11-17 11:22:16 -0800
commit3701794d330e9c86595761989cc8d59bbe8c88b1 (patch)
tree52d19400c9403133c6f0c4356dc69984c2f16d52 /util/tracediff
parent47789cc9745f3f708f3d6fb6e609fe3796fc00e4 (diff)
downloadgem5-3701794d330e9c86595761989cc8d59bbe8c88b1.tar.xz
Minor tracediff bug fixes.
Diffstat (limited to 'util/tracediff')
-rwxr-xr-xutil/tracediff7
1 files changed, 5 insertions, 2 deletions
diff --git a/util/tracediff b/util/tracediff
index 5f980ea5c..5349c303d 100755
--- a/util/tracediff
+++ b/util/tracediff
@@ -87,8 +87,11 @@ if (@ARGV < 1) {
foreach $arg (@ARGV) {
$a1 = $a2 = '';
- @subargs = split('#', $arg, -1);
+ @subargs = split('#', $arg);
foreach $subarg (@subargs) {
+ if ($subarg eq '') {
+ next;
+ }
@pair = split('\|', $subarg, -1); # -1 enables null trailing fields
if (@pair == 1) {
$a1 .= $subarg;
@@ -97,7 +100,7 @@ foreach $arg (@ARGV) {
$a1 .= $pair[0];
$a2 .= $pair[1];
} else {
- print 'Parse error: too many |s in ', $arg, '\n';
+ print 'Parse error: too many |s in ', $arg, "\n";
exit(1);
}
}