summaryrefslogtreecommitdiff
path: root/binutils/windmc.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2022-05-19 15:05:12 +0100
committerNick Clifton <nickc@redhat.com>2022-05-19 15:05:12 +0100
commit95086e1e54a726a0d7671d70640bc76e4fddf198 (patch)
tree8e8283dde5b40f111b4f6b834ddd304821c8f22d /binutils/windmc.c
parent18bd4744611b97e9fca41f97b871eea7bd66bd3e (diff)
downloadbinutils-gdb-95086e1e54a726a0d7671d70640bc76e4fddf198.tar.gz
Fix potentially uninitialised variables in the Windows tools
Diffstat (limited to 'binutils/windmc.c')
-rw-r--r--binutils/windmc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/binutils/windmc.c b/binutils/windmc.c
index f9a41694be4..b47da91f1bb 100644
--- a/binutils/windmc.c
+++ b/binutils/windmc.c
@@ -338,7 +338,7 @@ mc_add_node_lang (mc_node *root, const mc_keyword *lang, rc_uint_type vid)
static char *
convert_unicode_to_ACP (const unichar *usz)
{
- char *s;
+ char *s = NULL;
rc_uint_type l;
if (! usz)
@@ -607,7 +607,7 @@ mc_generate_bin_item (mc_node_lang *n, rc_uint_type *res_len)
else
{
rc_uint_type txt_len, l;
- char *cvt_txt;
+ char *cvt_txt = NULL;
codepage_from_unicode( &l, n->message, &cvt_txt, n->lang->lang_info.wincp);
if (! cvt_txt)
@@ -1105,7 +1105,7 @@ main (int argc, char **argv)
/* Load the input file and do code page transformations to UTF16. */
{
- unichar *u;
+ unichar *u = NULL;
rc_uint_type ul;
char *buff;
bfd_size_type flen;