diff options
author | Stig Bjørlykke <stig@bjorlykke.org> | 2008-02-03 15:38:20 +0000 |
---|---|---|
committer | Stig Bjørlykke <stig@bjorlykke.org> | 2008-02-03 15:38:20 +0000 |
commit | 47d744b59da83744623bea39c006eb7e2ec02de9 (patch) | |
tree | 17d9ec1526a37c793ee3d7cbd031091d1867dd7f /tap-iostat.c | |
parent | e59b5d6b8a963263b0c2dcf163e07b4318737d71 (diff) |
More rewrite of prohibited APIs (sprintf, strcpy, strcat).
svn path=/trunk/; revision=24258
Diffstat (limited to 'tap-iostat.c')
-rw-r--r-- | tap-iostat.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tap-iostat.c b/tap-iostat.c index 5833a46bf5..225af8254d 100644 --- a/tap-iostat.c +++ b/tap-iostat.c @@ -663,8 +663,7 @@ iostat_init(const char *optarg, void* userdata _U_) if(pos==str){ register_io_tap(io, i, NULL); } else if(pos==NULL) { - tmp=g_malloc(strlen(str)+1); - strcpy(tmp,str); + tmp=g_strdup(str); register_io_tap(io, i, tmp); } else { tmp=g_malloc((pos-str)+1); |