Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Plugins
pidgin-otr
Commits
03f11def
Commit
03f11def
authored
Jul 19, 2012
by
Ian Goldberg
Browse files
Change a malloc+strcpy into a strdup in process_receiving_im()
Thanks to Paul Wouters <paul@cypherpunks.ca> for the report.
parent
bf23e479
Changes
1
Show whitespace changes
Inline
Side-by-side
otr-plugin.c
View file @
03f11def
...
...
@@ -781,10 +781,7 @@ static gboolean process_receiving_im(PurpleAccount *account, char **who,
&
newmessage
,
&
tlvs
,
NULL
,
NULL
,
NULL
);
if
(
newmessage
)
{
char
*
ourm
=
malloc
(
strlen
(
newmessage
)
+
1
);
if
(
ourm
)
{
strcpy
(
ourm
,
newmessage
);
}
char
*
ourm
=
strdup
(
newmessage
);
otrl_message_free
(
newmessage
);
free
(
*
message
);
*
message
=
ourm
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment