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.175 by root, Wed Dec 1 04:43:12 2010 UTC vs.
Revision 1.177 by root, Thu Dec 30 07:19:31 2010 UTC

118 STRLEN stroffset; \ 118 STRLEN stroffset; \
119 SV *self; 119 SV *self;
120 120
121#define EIO_NO_WRAPPERS 1 121#define EIO_NO_WRAPPERS 1
122 122
123#include "libeio/config.h"
123#include "libeio/eio.h" 124#include "libeio/eio.h"
124 125
125#ifndef POSIX_FADV_NORMAL 126#ifndef POSIX_FADV_NORMAL
126# define POSIX_FADV_NORMAL 0 127# define POSIX_FADV_NORMAL 0
127#endif 128#endif
352 /* do not recreate the result IV from scratch each time */ 353 /* do not recreate the result IV from scratch each time */
353 if (expect_true (sv_result_cache)) 354 if (expect_true (sv_result_cache))
354 { 355 {
355 sv_result = sv_result_cache; sv_result_cache = 0; 356 sv_result = sv_result_cache; sv_result_cache = 0;
356 SvIV_set (sv_result, req->result); 357 SvIV_set (sv_result, req->result);
358 SvIOK_only (sv_result);
357 } 359 }
358 else 360 else
359 { 361 {
360 sv_result = newSViv (req->result); 362 sv_result = newSViv (req->result);
361 SvREADONLY_on (sv_result); 363 SvREADONLY_on (sv_result);
525 SvSETMAGIC (req->sv2); 527 SvSETMAGIC (req->sv2);
526 PUSHs (sv_result); 528 PUSHs (sv_result);
527 } 529 }
528 break; 530 break;
529 531
530 case EIO_DUP2: /* EIO_DUP2 actually means aio_close(), su fudge result value */ 532 case EIO_DUP2: /* EIO_DUP2 actually means aio_close(), so fudge result value */
531 if (req->result > 0) 533 if (req->result > 0)
532 SvIV_set (sv_result, 0); 534 SvIV_set (sv_result, 0);
533 /* FALLTHROUGH */ 535 /* FALLTHROUGH */
534 536
535 default: 537 default:

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines