php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #40680 process hangs after reaching set_time_limit() value
Submitted: 2007-03-01 10:14 UTC Modified: 2007-03-01 11:08 UTC
From: acv dot number dot one at gmail dot com Assigned:
Status: Not a bug Package: Scripting Engine problem
PHP Version: 5.2.1 OS: Linux FC 5
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: acv dot number dot one at gmail dot com
New email:
PHP Version: OS:

 

 [2007-03-01 10:14 UTC] acv dot number dot one at gmail dot com
Description:
------------
NOTE: I use php version 

PHP 5.1.4 (cli) (built: May  8 2006 08:41:41)

but it is not listed there. should I update it? I think it is for all 5.* versions.

Process hangs after reaching set_time_limit() value.

After the script executes, the php process which processed it hangs and the CPU% used remains the same (no resources freeing).

Reproduce code:
---------------
<?php
   set_time_limit(30);

 while(1)
  {
       a_function();  
  } //Call to a function which doesn't affect the "time run" value for the script.
?>

Expected result:
----------------
I expect the script to finish executing after 30 seconds + time needed for the called (e.g. system call) function.

Actual result:
--------------
The script runs for 30 seconds, but if at the moment the 30 seconds interval passes the called funciton is executed (e.g. system call) - the process hangs (the interpreter hangs in that funciton)

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-03-01 11:08 UTC] tony2001@php.net
Thank you for taking the time to report a problem with PHP.
Unfortunately you are not using a current version of PHP -- 
the problem might already be fixed. Please download a new
PHP version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.


 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Thu Oct 08 03:00:02 2026 UTC