blob: 0186b55e7e6a956b414fddbc87a8413b01aa978a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
--TEST--
shm_remove() tests
--SKIPIF--
<?php
if (!extension_loaded("sysvshm")){ print 'skip'; }
if (!function_exists('ftok')){ print 'skip'; }
?>
--FILE--
<?php
$key = ftok(__FILE__, 't');
$s = shm_attach($key, 1024);
var_dump(shm_remove($s));
shm_detach($s);
try {
shm_remove($s);
} catch (Error $exception) {
echo $exception->getMessage() . "\n";
}
echo "Done\n";
?>
--EXPECT--
bool(true)
Shared memory block has already been destroyed
Done
|