rexdex / recompiler

Xbox360 -> Windows executable converter
MIT License
1.64k stars 81 forks source link

Spaces in folder names don't work right #23

Open twist84 opened 6 years ago

twist84 commented 6 years ago

If you have a game in D:\Games\Consoles\X360\Homebrew\Quake 3\ after Quake the rest of the folder name doesn't get parsed.

rexdex commented 6 years ago

Is this in the GUI tools or via command line ?

twist84 commented 6 years ago

GUI tools, I haven't checked via command line

twist84 commented 6 years ago

Just checked via command line and it's the same even with quotation around the path"D:\Games\Consoles\X360\Homebrew\Quake 3\q3_360.xex"

sumit0190 commented 6 years ago

Yeah, that looks about right. CommandLine::Parse has this loop where we get the value of each property specified, and we do this by moving forward on the string, one character at a time, until we encounter a space. It's worth noting that argv actually gives us the whole path (with spaces, all in quotes), but we screw up when parsing it.

@rexdex I can take this if you want. Not sure if the GUI tools use the same API.

rexdex commented 6 years ago

Yeah, go ahead. In general the space is a separator unless it's in the "", maybe the logic is flawed there.