|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2010-10-22 15:45 UTC] kalle@php.net
-Package: Semaphore related
+Package: Documentation problem
[2010-10-23 08:30 UTC] kalle@php.net
[2010-10-23 08:30 UTC] kalle@php.net
-Status: Open
+Status: Closed
-Assigned To:
+Assigned To: kalle
[2010-10-23 08:30 UTC] kalle@php.net
[2020-02-07 06:08 UTC] phpdocbot@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 08 11:00:02 2026 UTC |
Description: ------------ The documentation says: resource shm_attach ( int $key [, int $memsize [, int $perm ]] ) , what's valid on 5.3, however versions prior to it used to return integer. ------- $f=trim(`mktemp`); $key=ftok($f,'a'); $shm = shm_attach($key, 100000); var_dump($shm); unlink($f); ----------- PHP 5.3.1-5 with Suhosin-Patch (cli) (built: Feb 22 2010 17:37:40) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies with Suhosin v0.9.29, Copyright (c) 2007, by SektionEins GmbH returns: resource(5) of type (sysvshm) ------------ PHP 5.2.6-1+lenny8 with Suhosin-Patch 0.9.6.2 (cli) (built: Mar 14 2010 08:14:04) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies with Xdebug v2.0.4, Copyright (c) 2002-2008, by Derick Rethans returns: int(5) Test script: --------------- $f=trim(`mktemp`); $key=ftok($f,'a'); $shm = shm_attach($key, 100000); var_dump($shm); unlink($f);