commit | 7b0bc8571465666d6cba79bda60b72a97f852c05 | [log] [tgz] |
---|---|---|
author | Kenny Root <kroot@google.com> | Fri Apr 27 15:33:58 2012 -0700 |
committer | Kenny Root <kroot@google.com> | Fri Apr 27 15:33:58 2012 -0700 |
tree | 66f1c614261d1e2f1d97f4381a0b7a3b001f32ed | |
parent | 344ca10856f3d3087a3288ce8f91ad83665d93fb [diff] |
Fix truncation of ASEC ids Change-Id: I1e6bfcc6b0a5be47e6fd19922fc81669f61b5dba
diff --git a/CommandListener.cpp b/CommandListener.cpp index d75d76c..dff4625 100644 --- a/CommandListener.cpp +++ b/CommandListener.cpp
@@ -290,7 +290,7 @@ !strcmp(&dent->d_name[name_len - 5], ".asec")) { char id[255]; memset(id, 0, sizeof(id)); - strlcpy(id, dent->d_name, name_len - 5); + strlcpy(id, dent->d_name, name_len - 4); cli->sendMsg(ResponseCode::AsecListResult, id, false); } }