Thanks for your advices DaWei!
I will remember them!

Is it possible to concatenate just an int to the char filename?

In that case I would be safe...