1--TEST--
2curl_share_setopt basic test
3--SKIPIF--
4<?php
5if (!extension_loaded("curl")) {
6	    exit("skip curl extension not loaded");
7}
8?>
9--FILE--
10<?php
11
12$sh = curl_share_init();
13var_dump(curl_share_setopt($sh, CURLSHOPT_SHARE, CURL_LOCK_DATA_COOKIE));
14var_dump(curl_share_setopt($sh, CURLSHOPT_UNSHARE, CURL_LOCK_DATA_DNS));
15var_dump(curl_share_setopt($sh, -1, 0));
16
17?>
18--EXPECTF--
19bool(true)
20bool(true)
21
22Warning: curl_share_setopt(): Invalid curl share configuration option in %s on line %d
23bool(false)
24