Commit 019391bc authored by Ramon Nou's avatar Ramon Nou
Browse files

cleanup

parent 48d9420f
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -464,7 +464,6 @@ struct logger {

        std::array<buffer_view, 3> buffers{};

        int i = 0;
        int m = 0;
        const char* addr = buffer;
        const char* p = nullptr;
@@ -475,7 +474,6 @@ struct logger {

            m += log_buffer_views(buffers);
            addr = p + 1;
            ++i;
        }

        // original line might not end with (or include) '\n'
+170 −540

File changed.

Preview size limit exceeded, changes collapsed.

+0 −2
Original line number Diff line number Diff line
@@ -141,11 +141,9 @@ struct SeqReadBenchmark {
            if (fd < 0) break;
            
            auto start = Timer::now();
            size_t total_read = 0;
            while (true) {
                int ret = read(fd, read_buf.data(), buf_size);
                if (ret <= 0) break;
                total_read += ret;
            }
            close(fd);
            fd = -1;
+5 −6
Original line number Diff line number Diff line
@@ -239,10 +239,9 @@ int main(int argc, char* argv[]) {
                DIR* d = opendir(tmp);
                if (d) {
                    struct dirent* entry;
                    int count = 0;
                    while ((entry = readdir(d)) != nullptr) {
                        if (strcmp(entry->d_name, ".") != 0 && strcmp(entry->d_name, "..") != 0) {
                            count++;
                            // process entry
                        }
                    }
                    closedir(d);
+1 −2
Original line number Diff line number Diff line
@@ -285,10 +285,9 @@ int main(int argc, char* argv[]) {
                DIR* d = opendir(tmp);
                if (d) {
                    struct dirent* entry;
                    int count = 0;
                    while ((entry = readdir(d)) != nullptr) {
                        if (strcmp(entry->d_name, ".") != 0 && strcmp(entry->d_name, "..") != 0) {
                            count++;
                            // process entry (count discarded)
                        }
                    }
                    closedir(d);
Loading