diff options
author | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2009-06-13 20:30:35 +0800 |
---|---|---|
committer | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2009-06-13 20:30:35 +0800 |
commit | be47b77b9d990d9ce0491a8358c77634367bf441 (patch) | |
tree | f9caf2111b94e07247b28ea39e5ee328b9b08370 | |
parent | f5ce7cce23d19eee389afe02c20f3a49c916e84f (diff) | |
download | pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.tar pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.tar.gz pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.tar.bz2 pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.tar.lz pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.tar.xz pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.tar.zst pttbbs-be47b77b9d990d9ce0491a8358c77634367bf441.zip |
* code refine to mbbsd
git-svn-id: http://opensvn.csie.org/pttbbs/trunk@4591 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | pttbbs/mbbsd/mbbsd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pttbbs/mbbsd/mbbsd.c b/pttbbs/mbbsd/mbbsd.c index 4cdf284d..f6f99cbb 100644 --- a/pttbbs/mbbsd/mbbsd.c +++ b/pttbbs/mbbsd/mbbsd.c @@ -1612,13 +1612,13 @@ bool parse_bindport_conf(const char *path, struct ProgramOption *option) while (fgets(buf, sizeof(buf), fp)) { - if (sscanf(buf, "%s %s", vprogram, vport) != 2 || + if (sscanf(buf, "%s%s", vprogram, vport) != 2 || strcmp(vprogram, "mbbsd") != 0) continue; if (strcmp(vport, "tunnel") == 0) { - if (sscanf(buf, "%s %s %s", vprogram, vport, vopt) != 3) + if (sscanf(buf, "%*s%*s%s", vopt) != 1 || !*vopt) { fprintf(stderr, "error: invalid tunnel setting in %s.\r\n", path); |