Re: Calling a C function with a timeout
Chris Clark <[email protected]> Wed, 09 Mar 2011 10:04:48 -0800
| Newsgroups | gmane.comp.python.ctypes |
|---|---|
| Message-ID | <[email protected]> |
Michel Claveau wrote: > Je pense que, en passant par subprocess, ça irait mieux. En effet, on a > terminate() à disposition. > I concur, either use a subprocess (as suggested by Michel) which you can then kill, or modify the C code to support a time out. This isn't something you can deal with as you surrendered the stack to the function, it is now in control until it returns. Chris ------------------------------------------------------------------------------ Colocation vs. Managed Hosting A question and answer guide to determining the best fit for your organization - today and in the future. http://p.sf.net/sfu/internap-sfd2d