Sponsored Content
Top Forums Programming How to cancel a thread safely from the initial thread? Post 70471 by alan.zhao on Friday 29th of April 2005 03:44:01 AM
Old 04-29-2005
How to cancel a thread safely from the initial thread?

how about asynchronous canceling?
or with signal?
if with signal whether it effects the process?
my english so badly Smilie Smilie
 

3 More Discussions You Might Find Interesting

1. Programming

Parent Thread Of Child Thread

Parent Thread Of Child Thread Suppose a process creates some threads say threadC and threadD. Later on each of these threads create new child threads say threadC1, threadC2, threadC3 etc. So a tree of threads will get created. Is there any way to find out the parent thread of one such... (1 Reply)
Discussion started by: rupeshkp728
1 Replies

2. UNIX for Dummies Questions & Answers

Difference between handle to the thread HANDLE and thread identifier pthread_t

This question might be silly but its confusing me a bit: What is the difference between handle to the thread HANDLE and thread identifier pthread_t? ---------- Post updated at 01:52 PM ---------- Previous update was at 01:48 PM ---------- Sorry I saw details and HANDLE is in windows and... (0 Replies)
Discussion started by: rupeshkp728
0 Replies

3. Forum Support Area for Unregistered Users & Account Problems

Not able to post thread/reply to thread

Dear Moderator I am not able to post any new thread or post reply to mine old thread. Kindly help as i am stuck on one problem and needed suggestion. Regards Jaydeep (1 Reply)
Discussion started by: jaydeep_sadaria
1 Replies
aio_suspend(2)							System Calls Manual						    aio_suspend(2)

NAME
aio_suspend() - wait for an asynchronous I/O operation to complete SYNOPSIS
DESCRIPTION
The function suspends the calling process or thread until at least one of the asynchronous I/O operations initiated with one of the point- ers contained in has completed, or a signal interrupts the function, or timeout is not and the time interval specified by timeout has passed. Multiple threads may issue simultaneous calls to referencing one or more in common. To use this function, link in the realtime library by specifying on the compiler or linker command line. RETURN VALUE
returns the following values: Successful completion. Either there were no in or at least one of the asynchronous I/O operations enqueued for an referenced by has com- pleted. The completion status of the referenced asynchronous I/O operations must be determined using and for each relevant Failure. The process thread is not suspended and is set to indicate the error. If any of the indicated asynchronous I/O operations has already completed at the time of the call to then returns immediately. If is 0 (zero), the immediately returns success. Any in is silently ignored. If all of the in are the immediately returns success. ERRORS
If detects one of the following error conditions, is set to the indicated value: [EAGAIN] System-wide or per-process resources were not available to process the request. [EAGAIN] The time interval specified in the referenced by timeout passed before any of the asynchronous I/O operations enqueued for one of the entries referenced in completed. [EINVAL] The value of the argument was negative or exceeded the maximum value allowed. The maximum value allowed can be obtained using the call with the argument [EINVAL] One or more of the pointers in does not identify an asynchronous operation enqueued by or and for which has not yet been called. pointers associated with will yield this error. [EINTR] A signal was delivered to the process while was waiting. Completion of asynchronous operations can cause signal delivery. SEE ALSO
aio_cancel(2), aio_error(2), aio_fsync(2), aio_read(2), aio_return(2), aio_write(2), lio_listio(2), pause(2), aio(5). STANDARDS CONFORMANCE
aio_suspend(2)
All times are GMT -4. The time now is 06:52 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy