bugfix: minor memory corruption. Internal tests work. 44/38244/1
authorMaciej J. Karpiuk <m.karpiuk2@samsung.com>
Wed, 15 Apr 2015 09:04:20 +0000 (11:04 +0200)
committerMaciej J. Karpiuk <m.karpiuk2@samsung.com>
Wed, 15 Apr 2015 09:04:20 +0000 (11:04 +0200)
Change-Id: Ie6cc846ac066a6d86f0d2642a9906c08b4d35068

src/manager/service/key-provider.cpp

index d50e131..48db9c0 100644 (file)
@@ -645,7 +645,7 @@ char * KeyProvider::concat_password_user(const char *user, const char *password)
 
     memset(concat_user_pass, '\0', concat_user_pass_len);
     memcpy(concat_user_pass, password, strlen(password));
-    memcpy(&(concat_user_pass[strlen(password)]), user, strlen(user));
+    memcpy(&(concat_user_pass[strlen(password)]), resized_user, strlen(resized_user));
     concat_user_pass[strlen(resized_user) + strlen(password)] = '\0';
 
     delete[] resized_user;