projects
/
blktrace.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c615ce2
)
Fixed incorrect sizeof instead of strlen in btt/rstats.c
author
Alan D. Brunelle
<alan.brunelle@hp.com>
Mon, 22 Mar 2010 14:21:12 +0000
(10:21 -0400)
committer
Alan D. Brunelle
<alan.brunelle@hp.com>
Mon, 22 Mar 2010 14:21:12 +0000
(10:21 -0400)
btt/rstats.c
patch
|
blob
|
blame
|
history
diff --git
a/btt/rstats.c
b/btt/rstats.c
index 71f010bfaa27bfbe6d0fbc170f64e85873996c5d..5a336fe44ecf059230d32c638acc6fe5d705e50d 100644
(file)
--- a/
btt/rstats.c
+++ b/
btt/rstats.c
@@
-38,7
+38,7
@@
static LIST_HEAD(rstats);
static int do_open(struct files *fip, char *bn, char *pn)
{
- fip->nm = malloc(s
izeof
(bn) + 16);
+ fip->nm = malloc(s
trlen
(bn) + 16);
sprintf(fip->nm, "%s_%s.dat", bn, pn);
fip->fp = my_fopen(fip->nm, "w");
@@
-55,6
+55,7
@@
static int init_rsip(struct rstat *rsip, struct d_info *dip)
{
char *nm = dip ? dip->dip_name : "sys";
+ rsip->base_sec = -1;
rsip->ios = rsip->nblks = 0;
if (do_open(&rsip->files[0], nm, "iops_fp") ||
do_open(&rsip->files[1], nm, "mbps_fp"))