Wednesday, March 26, 2008

AppTapp Exec bug

I released my project to a couple of friendly users. After giving it a try, one of the testers came back and told me the installer was leaving crufty directories lying around in the root directory.

I eventually tracked it down to this:

   <string>/bin/mkdir -p "/var/root/Media/EBooks/Beyond World's End"</string>

Now, if this was in a shell, or passed to the OS using "system" or a similar call, it would work. However, it seems that they are using direct calls to exec. I can't really tell, because AppTapp is oddly closed source.

The directories it was creating were:

  • "/var/root/Media/EBooks/Beyond
  • /World's
  • /End"


Next up, I tried escaping the spaces, again with no luck. It looks like the code is splitting the parameters out through the use of spaces and ignores any attempt at grouping the packager might make.

Luckily CopyPath does the right thing, properly handling the spaces. It even creates parent directories, which is why I was using mkdir in the first place.

Now to figure out how to host it on Amazon S3. I really don't want a 2.5meg file being slurped across my cable modem every day!


Damian said...

1) "Use Amazon", Damian says
2) "Too expensive", Jason says
3) ...
4) "I'm using Amazon", Jason says

Jason Pollock said...


Bah! I say!

I went with Amazon because it was a single click to set up. Yep, one click. If you have an Amazon account, it's just like buying a book. Easier, in fact, because you don't have to choose shipping!