Message ID | 1360284301.17736.154.camel@auk59.llnl.gov (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Hal Rosenstock |
Headers | show |
On 2/7/2013 7:45 PM, Albert Chu wrote: > Parse of attribute did not properly remove whitespace before it. So > > PerformanceSet "H-0002c90300325280" PortCounters.SymbolErrorCounter=3 > > would work but > > PerformanceSet "H-0002c90300325280" PortCounters.SymbolErrorCounter=3\ > > would not. > > Signed-off-by: Albert Chu <chu11@llnl.gov> Thanks. Applied. -- Hal -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/ibsim/sim_cmd.c b/ibsim/sim_cmd.c index f44df93..83ad52d 100644 --- a/ibsim/sim_cmd.c +++ b/ibsim/sim_cmd.c @@ -911,7 +911,9 @@ static int do_perf_counter_set(FILE *f, char *line) return -1; } - strsep(&s, " "); + if (s && *s) + while (isspace(*s)) + s++; attr = strsep(&s, "."); if(s == NULL) goto format_error;
Parse of attribute did not properly remove whitespace before it. So PerformanceSet "H-0002c90300325280" PortCounters.SymbolErrorCounter=3 would work but PerformanceSet "H-0002c90300325280" PortCounters.SymbolErrorCounter=3\ would not. Signed-off-by: Albert Chu <chu11@llnl.gov> --- ibsim/sim_cmd.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)