fixed fstr/esprintf code for linux