Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bcfe9749 authored by Marco Nelissen's avatar Marco Nelissen
Browse files

Add nullptr checks

This code is never actually called with NULL pointers, but since we were
already checking for NULL, might as well do it everywhere.

Bug: 111882151
Test: build
Change-Id: Ia121a74c010262ac6023030e5d0fc04deb07e047
parent 904ca64b
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -67,8 +67,12 @@ struct DataSourceBaseReader : public mkvparser::IMkvReader {
    virtual int Length(long long* total, long long* available) {
        off64_t size;
        if (mSource->getSize(&size) != OK) {
            if (total) {
                *total = -1;
            }
            if (available) {
                *available = (long long)((1ull << 63) - 1);
            }

            return 0;
        }