bool MDFN_DumpToFile(const char *filename, int compress, const void *data, uint64 length) { std::vector<PtrLengthPair> tmp_pairs; #if defined CONFIG_BASE_PS3 || (defined __APPLE__ && defined __ARM_ARCH_6K__) tmp_pairs.push_back(PtrLengthPair(data, length)); #else tmp_pairs.emplace_back(data, length); #endif return(MDFN_DumpToFileReal(filename, compress, tmp_pairs)); }
bool MDFN_DumpToFile(const std::string& path, const std::vector<PtrLengthPair> &pearpairs, bool throw_on_error) { try { MDFN_DumpToFileReal(path, pearpairs); } catch(std::exception &e) { if(throw_on_error) throw; else { MDFN_PrintError("%s", e.what()); return(false); } } return(true); }
bool MDFN_DumpToFile(const char *filename, int compress, const void *data, uint64 length) { std::vector<PtrLengthPair> tmp_pairs; tmp_pairs.push_back(PtrLengthPair(data, length)); return(MDFN_DumpToFileReal(filename, compress, tmp_pairs)); }
bool MDFN_DumpToFile(const char *filename, int compress, const std::vector<PtrLengthPair> &pearpairs) { return(MDFN_DumpToFileReal(filename, compress, pearpairs)); }