mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-22 05:40:01 -06:00
NetworkCaptureLogger: Allow PCAP shared read access on Windows
This commit is contained in:
@ -20,6 +20,12 @@ enum class SeekOrigin
|
||||
End,
|
||||
};
|
||||
|
||||
enum class SharedAccess
|
||||
{
|
||||
Default,
|
||||
Read,
|
||||
};
|
||||
|
||||
// simple wrapper for cstdlib file functions to
|
||||
// hopefully will make error checking easier
|
||||
// and make forgetting an fclose() harder
|
||||
@ -28,7 +34,8 @@ class IOFile
|
||||
public:
|
||||
IOFile();
|
||||
IOFile(std::FILE* file);
|
||||
IOFile(const std::string& filename, const char openmode[]);
|
||||
IOFile(const std::string& filename, const char openmode[],
|
||||
SharedAccess sh = SharedAccess::Default);
|
||||
|
||||
~IOFile();
|
||||
|
||||
@ -40,7 +47,8 @@ public:
|
||||
|
||||
void Swap(IOFile& other) noexcept;
|
||||
|
||||
bool Open(const std::string& filename, const char openmode[]);
|
||||
bool Open(const std::string& filename, const char openmode[],
|
||||
SharedAccess sh = SharedAccess::Default);
|
||||
bool Close();
|
||||
|
||||
template <typename T>
|
||||
|
Reference in New Issue
Block a user