Skip to content

Commit

Permalink
Merge pull request s-macke#2 from mft1/master
Browse files Browse the repository at this point in the history
Fixed security vulnerability for arbitrary code execution
  • Loading branch information
s-macke committed Jun 3, 2015
2 parents 5a63e72 + 1aa2725 commit 78f363d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,8 @@ int main(int argc, char **argv)
{
if (argv[i][0] != '-')
{
strcat(input, argv[i]);
strcat(input, " ");
strncat(input, argv[i], 256);
strncat(input, " ", 256);
} else
{
if (strcmp(&argv[i][1], "wav")==0)
Expand Down Expand Up @@ -230,11 +230,11 @@ int main(int argc, char **argv)

if (!phonetic)
{
strcat(input, "[");
strncat(input, "[", 256);
if (!TextToPhonemes(input)) return 1;
if (debug)
printf("phonetic input: %s\n", input);
} else strcat(input, "\x9b");
} else strncat(input, "\x9b", 256);

#ifdef USESDL
if ( SDL_Init(SDL_INIT_AUDIO) < 0 )
Expand Down

0 comments on commit 78f363d

Please sign in to comment.