trafodion-codereview mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zellerh <>
Subject [GitHub] incubator-trafodion pull request #953: [TRAFODION-2478] Reduce the number of...
Date Mon, 13 Feb 2017 18:46:23 GMT
Github user zellerh commented on a diff in the pull request:
    --- Diff: core/sql/cli/memorymonitor.cpp ---
    @@ -102,12 +102,18 @@ MemoryMonitor::MemoryMonitor(Lng32 windowSize,
       // if the windowSize is 0, we do not need memory monitor.
    -  char buffer[1024];
    +  char buffer[2048];
       char *currPtr;
       size_t bytesRead;
       fd_meminfo_ = fopen("/proc/meminfo", "r");
       if (fd_meminfo_) {
    -    bytesRead = fread(buffer, 1, 1024, fd_meminfo_);
    +    bytesRead = fread(buffer, 1, 2048, fd_meminfo_);
    +    if (ferror(fd_meminfo_))
    +       assert(false); 
    --- End diff --
    Could you remind me what this assert would do? Would it just write a log entry or would
it kill the process and cause a core dump? I would say we shouldn't cause a failure of the

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

View raw message