diff options
author | okan <okan> | 2008-07-11 14:24:34 +0000 |
---|---|---|
committer | okan <okan> | 2008-07-11 14:24:34 +0000 |
commit | 8be175b175f04c4c16ec4be63bab6b1d2b0ebbfd (patch) | |
tree | 2aad0db8ebf663fb009104f1cdcba6a8e34dd065 | |
parent | 85e6c613606d444e08a9b1a2d53049c46a57e2a2 (diff) | |
download | cwm-8be175b175f04c4c16ec4be63bab6b1d2b0ebbfd.tar.gz cwm-8be175b175f04c4c16ec4be63bab6b1d2b0ebbfd.tar.xz cwm-8be175b175f04c4c16ec4be63bab6b1d2b0ebbfd.zip |
replace snprintf with strlcpy
ok oga@
-rw-r--r-- | conf.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/conf.c b/conf.c index e586770..10d891a 100644 --- a/conf.c +++ b/conf.c @@ -194,8 +194,7 @@ conf_setup(struct conf *c, const char *conf_file) if (stat(conf_file, &sb) == -1 || !(sb.st_mode & S_IFREG)) errx(1, "%s: %s", conf_file, strerror(errno)); else - snprintf(c->conf_path, sizeof(c->conf_path), "%s", - conf_file); + strlcpy(c->conf_path, conf_file, sizeof(c->conf_path)); conf_init(c); |