php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #9676 Feature request for set_time_limit
Submitted: 2001-03-10 22:04 UTC Modified: 2010-11-24 09:02 UTC
From: tboothby at felfel dot com Assigned:
Status: Not a bug Package: *General Issues
PHP Version: 4.0.4pl1 OS: Red Hat Linux 6.2
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
21 + 49 = ?
Subscribe to this entry?

 
 [2001-03-10 22:04 UTC] tboothby at felfel dot com
Taken from the user notes about set_time_limit()

"malhavoc at stomped.com
23-Feb-2001 05:48 
I've noticed that using this function doesn't seem to block things that make calls to services and wait for a response. Setting set_time_limit(2) and then making a call to gethostbyaddr(ip.that.does.not.resolve) just sits there until it times out. 

It would be -really- nice if there was a perl-esque type function like alarm() that lets you set timeouts for specific sections of code, rather than entire scripts. I'd have great use for a feature that would enable me to run non crucial pieces of code for a few seconds, and then give up and move on if it takes too long."

This feature would be very nice.
Thanks for all your efforts,
   --tom

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-11-24 09:02 UTC] jani@php.net
-Status: Open +Status: Bogus -Package: Feature/Change Request +Package: *General Issues
 [2010-11-24 09:02 UTC] jani@php.net
Same as bug #11592 which is better analyzed.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 15:01:30 2024 UTC