Changeset 0521a1a


Ignore:
Timestamp:
Mar 22, 2022, 4:01:51 PM (4 months ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
enum, master
Children:
4479890
Parents:
ff7b2de
Message:

Fixed meta dumpable

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/meta/dumpable.cfa

    rff7b2de r0521a1a  
    115115
    116116        try {
    117                 const char * expected = "core";
    118                 const int sz = sizeof("core");
     117                const char * expected = "core\n";
     118                const int sz = sizeof("core\n");
    119119                char buf[512];
    120120                ret = read(cp, buf, 512);
     
    123123                        return;
    124124                }
    125                 if(strncmp(expected, buf, sz) != 0) {
     125                ret = strncmp(expected, buf, sz - 1);
     126                if(ret != 0) {
    126127                        serr | "/proc/sys/kernel/core_pattern does not contain 'core', was:" | nl | nl | buf | nl
    127128                             | "Test script expect cores files to be dumped with name 'core' in current working directory." | nl
Note: See TracChangeset for help on using the changeset viewer.