summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWang Liyong <liyong.x.wang@sonymobile.com>2013-07-18 16:37:07 +0200
committerJohan Redestig <johan.redestig@sonymobile.com>2013-07-18 16:37:07 +0200
commit1c4a77955acdb730d017b15e9a92ca511e6ca106 (patch)
tree35b9d5a27c7b261899a4fe20ab9ba585083b42bc
parent4ea5bd0540bf3b4b6767815b5c9e41a7146f749c (diff)
downloadnetd-1c4a77955acdb730d017b15e9a92ca511e6ca106.tar.gz
Fix memset call
Parameters was passed in the wrong order. Change-Id: I1d4d68f1ba729bf54da84cbcb5f631938ac697f2
-rw-r--r--CommandListener.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/CommandListener.cpp b/CommandListener.cpp
index 6f81524c..467a9aa6 100644
--- a/CommandListener.cpp
+++ b/CommandListener.cpp
@@ -785,8 +785,8 @@ int CommandListener::PppdCmd::runCommand(SocketClient *cli,
if (!strcmp(argv[1], "attach")) {
struct in_addr l, r, dns1, dns2;
- memset(&dns1, sizeof(struct in_addr), 0);
- memset(&dns2, sizeof(struct in_addr), 0);
+ memset(&dns1, 0, sizeof(struct in_addr));
+ memset(&dns2, 0, sizeof(struct in_addr));
if (!inet_aton(argv[3], &l)) {
cli->sendMsg(ResponseCode::CommandParameterError, "Invalid local address", false);