Ignore:
Timestamp:
Nov 24, 2016, 1:14:11 PM (9 years ago)
Author:
Silvan Scherrer
Message:

Samba Server: update vendor to version 4.4.3

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vendor/current/tests/fcntl_lock.c

    r414 r988  
    6363                lock.l_type = F_WRLCK;
    6464                lock.l_whence = SEEK_SET;
    65                 lock.l_start = 0;
     65                lock.l_start = 0x100000000LL;
    6666                lock.l_len = 4;
    6767                lock.l_pid = getpid();
     
    9393        lock.l_whence = SEEK_SET;
    9494        lock.l_start = 0;
    95         lock.l_len = 4;
     95        lock.l_len = 0x100000004LL;
    9696        lock.l_pid = getpid();
    9797
    98         /* set a 4 byte write lock */
    99         fcntl(fd,F_SETLK,&lock);
     98        /* set a 100000004 byte write lock, should conflict with the above */
     99        ret = fcntl(fd,F_SETLK,&lock);
    100100
    101101        sys_waitpid(pid, &status, 0);
    102102
    103103        unlink(DATA);
     104
     105        if (ret != 0) {
     106                fprintf(stderr,"ERROR: failed to lock %s (errno=%d)\n",
     107                        DATA, (int)errno);
     108                exit(1);
     109        }
     110
     111        if (lock.l_len < 0x100000004LL) {
     112                fprintf(stderr,"ERROR: settign lock overflowed\n");
     113                exit(1);
     114        }
    104115
    105116#if defined(WIFEXITED) && defined(WEXITSTATUS)
Note: See TracChangeset for help on using the changeset viewer.