From 239183cfe675684aeca1a2b24362ca5e0a82809d Mon Sep 17 00:00:00 2001 From: Nathan Binkert Date: Tue, 17 Aug 2004 11:19:04 -0400 Subject: Fix a small bug in parameter processing that would always result in at least on entry in a VectorParam even if the string was empty. sim/param.cc: if there are no parameters, leave the vector empty. --HG-- extra : convert_revision : d0d41baa8c77651a27ac6a4d02cc388711f47dbe --- sim/param.cc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sim') diff --git a/sim/param.cc b/sim/param.cc index 4f9d0a577..84ecbf8f9 100644 --- a/sim/param.cc +++ b/sim/param.cc @@ -211,6 +211,11 @@ template void VectorParam::parse(const string &s) { + if (s.empty()) { + wasSet = true; + return; + } + vector tokens; tokenize(tokens, s, ' '); -- cgit v1.2.3