Use relative path in fopen for file transfer