Re: There are still bugs in such routine tasks?
Exactly, there's no excuse for us to still be living in a world where C code is written like this. This is some kind of Path.join() or File.join() functionality that is handled in one place by modern languages/libraries. Rewriting this kind of crap, even with safe functions like snprintf(), is absurd in this day and age.