ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/IO-AIO/AIO.xs
(Generate patch)

Comparing IO-AIO/AIO.xs (file contents):
Revision 1.243 by root, Mon Jul 18 07:48:01 2016 UTC vs.
Revision 1.246 by root, Fri Jun 23 21:43:51 2017 UTC

996 const_iv (MAP_GROWSDOWN) 996 const_iv (MAP_GROWSDOWN)
997 const_iv (MAP_32BIT) 997 const_iv (MAP_32BIT)
998 const_iv (MAP_HUGETLB) 998 const_iv (MAP_HUGETLB)
999 const_iv (MAP_STACK) 999 const_iv (MAP_STACK)
1000 1000
1001 const_iv (F_DUPFD_CLOEXEC)
1002
1003 const_iv (F_OFD_GETLK)
1004 const_iv (F_OFD_SETLK)
1005 const_iv (F_OFD_GETLKW)
1006
1001 const_iv (FIFREEZE) 1007 const_iv (FIFREEZE)
1002 const_iv (FITHAW) 1008 const_iv (FITHAW)
1003 const_iv (FITRIM) 1009 const_iv (FITRIM)
1004 const_iv (FICLONE) 1010 const_iv (FICLONE)
1005 const_iv (FICLONERANGE) 1011 const_iv (FICLONERANGE)
1096 const_eio (FALLOC_FL_KEEP_SIZE) 1102 const_eio (FALLOC_FL_KEEP_SIZE)
1097 const_eio (FALLOC_FL_PUNCH_HOLE) 1103 const_eio (FALLOC_FL_PUNCH_HOLE)
1098 const_eio (FALLOC_FL_COLLAPSE_RANGE) 1104 const_eio (FALLOC_FL_COLLAPSE_RANGE)
1099 const_eio (FALLOC_FL_ZERO_RANGE) 1105 const_eio (FALLOC_FL_ZERO_RANGE)
1100 1106
1107 const_eio (RENAME_NOREPLACE)
1108 const_eio (RENAME_EXCHANGE)
1109 const_eio (RENAME_WHITEOUT)
1110
1101 const_eio (READDIR_DENTS) 1111 const_eio (READDIR_DENTS)
1102 const_eio (READDIR_DIRS_FIRST) 1112 const_eio (READDIR_DIRS_FIRST)
1103 const_eio (READDIR_STAT_ORDER) 1113 const_eio (READDIR_STAT_ORDER)
1104 const_eio (READDIR_FOUND_UNKNOWN) 1114 const_eio (READDIR_FOUND_UNKNOWN)
1105 1115
1591 1601
1592 REQ_SEND; 1602 REQ_SEND;
1593} 1603}
1594 1604
1595void 1605void
1606aio_rename2 (SV8 *oldpath, SV8 *newpath, int flags = 0, SV *callback = &PL_sv_undef)
1607 PPCODE:
1608{
1609 eio_wd wd2 = 0;
1610 dREQ;
1611
1612 req->type = EIO_RENAME;
1613 req_set_path1 (req, oldpath);
1614 req_set_path (req, newpath, &req->sv2, &req->sv4, &wd2, &req->ptr2);
1615 req->int2 = flags;
1616 req->int3 = (long)wd2;
1617
1618 REQ_SEND;
1619}
1620
1621void
1596aio_mknod (SV8 *pathname, int mode, UV dev, SV *callback = &PL_sv_undef) 1622aio_mknod (SV8 *pathname, int mode, UV dev, SV *callback = &PL_sv_undef)
1597 PPCODE: 1623 PPCODE:
1598{ 1624{
1599 dREQ; 1625 dREQ;
1600 1626
1605 1631
1606 REQ_SEND; 1632 REQ_SEND;
1607} 1633}
1608 1634
1609void 1635void
1610aio_mtouch (SV8 *data, IV offset = 0, SV *length = &PL_sv_undef, int flags = 0, SV *callback = &PL_sv_undef) 1636aio_mtouch (SV8 *data, IV offset = 0, SV *length = &PL_sv_undef, int flags = -1, SV *callback = &PL_sv_undef)
1611 ALIAS: 1637 ALIAS:
1612 aio_mtouch = EIO_MTOUCH 1638 aio_mtouch = EIO_MTOUCH
1613 aio_msync = EIO_MSYNC 1639 aio_msync = EIO_MSYNC
1614 PPCODE: 1640 PPCODE:
1615{ 1641{
1616 STRLEN svlen; 1642 STRLEN svlen;
1617 char *svptr = SvPVbyte (data, svlen); 1643 char *svptr = SvPVbyte (data, svlen);
1618 UV len = SvUV (length); 1644 UV len = SvUV (length);
1645
1646 if (flags < 0)
1647 flags = ix == EIO_MSYNC ? EIO_MS_SYNC : 0;
1619 1648
1620 if (offset < 0) 1649 if (offset < 0)
1621 offset += svlen; 1650 offset += svlen;
1622 1651
1623 if (offset < 0 || offset > svlen) 1652 if (offset < 0 || offset > svlen)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines