Changeset 204 for branches/samba-3.2.x/source/smbd/aio.c
- Timestamp:
- May 20, 2009, 6:46:53 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/samba-3.2.x/source/smbd/aio.c
r133 r204 25 25 /* The signal we'll use to signify aio done. */ 26 26 #ifndef RT_SIGNAL_AIO 27 #define RT_SIGNAL_AIO (SIGRTMIN+3) 27 #ifndef SIGRTMIN 28 #define SIGRTMIN NSIG 29 #endif 30 #define RT_SIGNAL_AIO (SIGRTMIN+3) 31 #endif 32 33 #ifndef HAVE_STRUCT_SIGEVENT_SIGEV_VALUE_SIVAL_PTR 34 #ifdef HAVE_STRUCT_SIGEVENT_SIGEV_VALUE_SIGVAL_PTR 35 #define sival_int sigval_int 36 #define sival_ptr sigval_ptr 37 #endif 28 38 #endif 29 39 … … 269 279 a->aio_sigevent.sigev_value.sival_int = aio_ex->mid; 270 280 281 become_root(); 271 282 if (SMB_VFS_AIO_READ(fsp,a) == -1) { 272 283 DEBUG(0,("schedule_aio_read_and_X: aio_read failed. " 273 284 "Error %s\n", strerror(errno) )); 274 285 delete_aio_ex(aio_ex); 275 return False; 276 } 286 unbecome_root(); 287 return False; 288 } 289 unbecome_root(); 277 290 278 291 DEBUG(10,("schedule_aio_read_and_X: scheduled aio_read for file %s, " … … 367 380 a->aio_sigevent.sigev_value.sival_int = aio_ex->mid; 368 381 382 become_root(); 369 383 if (SMB_VFS_AIO_WRITE(fsp,a) == -1) { 370 384 DEBUG(3,("schedule_aio_wrote_and_X: aio_write failed. " 371 385 "Error %s\n", strerror(errno) )); 372 386 delete_aio_ex(aio_ex); 373 return False; 374 } 375 387 unbecome_root(); 388 return False; 389 } 390 unbecome_root(); 391 376 392 release_level_2_oplocks_on_change(fsp); 377 393 … … 576 592 int err; 577 593 594 if(!aio_ex) { 595 DEBUG(3, ("handle_aio_completed: Non-existing aio_ex passed\n")); 596 return false; 597 } 598 578 599 /* Ensure the operation has really completed. */ 579 600 if (SMB_VFS_AIO_ERROR(aio_ex->fsp, &aio_ex->acb) == EINPROGRESS) {
Note:
See TracChangeset
for help on using the changeset viewer.