MCPcopy Create free account
hub / github.com/FFMS/ffms2 / ffms_fopen

Function ffms_fopen

src/core/filehandle.cpp:31–43  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29}
30
31static AVIOContext *ffms_fopen(const char *filename, const char *mode) {
32 int flags = 0;
33 if (strchr(mode, 'r'))
34 flags |= AVIO_FLAG_READ;
35 if (strchr(mode, 'w'))
36 flags |= AVIO_FLAG_WRITE;
37
38 AVIOContext *ctx;
39 int ret = avio_open2(&ctx, filename, flags, nullptr, nullptr);
40 if (ret < 0)
41 return nullptr;
42 return ctx;
43}
44
45FileHandle::FileHandle(const char *filename, const char *mode, int error_source, int error_cause)
46 : avio(ffms_fopen(filename, mode))

Callers 1

FileHandleMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected