Menu

#14 COMMAND string is limited to 1023 bytes

0.9.7
open
5
2012-10-03
2007-02-03
No

Under Linux (or cygwin) the shell could generate very easy a longer line. For example if the program argument is "*.jpg" (I would like to write a simple test application an image viewer) AND the current directory
containing a lot of (more than 100) jpeg files the shell will generate a list from all of these file names which will be longer than 1023 character.

In console-main.c there is no check on the max so the code will overwrite the variable in memory after the allocated command string.

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.