Replace sprintf with snprintf to avoid a crash.
authorHafiz Abid Qadeer <hafiz_abid@mentor.com>
Tue, 28 Apr 2015 14:16:00 +0000 (14:16 +0000)
committerHafiz Abid Qadeer <hafiz_abid@mentor.com>
Tue, 28 Apr 2015 14:16:00 +0000 (14:16 +0000)
commit7f2f0ccb0a145dd0b4618c15f16777c43568b3d0
tree72ee242e9db55a5a4768b381358429fad1b23b56
parent7dea2e39824eb1d699c41bb113ce1f2b2a17d211
Replace sprintf with snprintf to avoid a crash.
During testing -data-list-register-values, I saw a crash here due to buffer overflow.
This commit should fix the crash. There is still problem with printing 1-byte register
in some cases that I will fix separately.

No regression on MI test cases.

llvm-svn: 235991
lldb/tools/lldb-mi/MIUtilString.cpp