commit | d5b4c2f4938aaebc392669111385c3cf50dd309f | [log] [tgz] |
---|---|---|
author | Chen Gang <gang.chen@asianux.com> | Mon May 27 17:55:13 2013 +0800 |
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | Tue May 28 10:35:28 2013 +0200 |
tree | 0e1f9dc2ea24500981a61d2adec13e46080a5a93 | |
parent | 9acf73b7d06eaa3fbfbfafc9c835f8fe0d751eff [diff] |
arch: s390: appldata: using strncpy() and strnlen() instead of sprintf() 'buf[2]' is 2 bytes length, and sprintf() will append '\0' at the end of string "?\n", so original implementation is memory overflow. Need use strncpy() and strnlen() instead of sprintf(). Signed-off-by: Chen Gang <gang.chen@asianux.com> Signed-off-by: Gerald Schaefer <gerald.schaefer@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>