Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:41795 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 88471 invoked from network); 10 Nov 2008 10:05:22 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 10 Nov 2008 10:05:22 -0000 Authentication-Results: pb1.pair.com header.from=zhangsilly@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=zhangsilly@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.198.234 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: zhangsilly@gmail.com X-Host-Fingerprint: 209.85.198.234 rv-out-0506.google.com Received: from [209.85.198.234] ([209.85.198.234:51584] helo=rv-out-0506.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id ED/4D-13010-16708194 for ; Mon, 10 Nov 2008 05:05:22 -0500 Received: by rv-out-0506.google.com with SMTP id g9so610766rvb.2 for ; Mon, 10 Nov 2008 02:05:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type; bh=baiPuFqGbRNp3lP/u6YOC2NlpwO968Lq5B4au+RGqUw=; b=OGUzH5VouHfipx4C4AIMc8FzDSgSHTzvhZyJ8j0OpsS8BalIpPyuwboVo/cZdzBz8b BvC9PSEmJ0uHAM/pFu5zf3UGe9QXzV7mIECdJejWItPliPVyk1v5CkjQljlLfl5pjKEn n5TjjCrUtifUOKAjztuWaJFgQHI0jkJukm0Ts= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type; b=X/KB7ztJvkMca8NoMh/74LhfeHOmhF5wfrxoXVIwzR4Wyp4eHx4YDFs8/NKmQBnIbf SU48uM3NoQ9f5kIGtgr5OlR0cGQsWlYj9aT9NEEPCzKNdXRwybr0iq62slHqMI1S7BGQ vag+XzidXWzghEYSoWAyvx8FcxbBDSmy8i9eI= Received: by 10.142.174.8 with SMTP id w8mr2306380wfe.225.1226311519080; Mon, 10 Nov 2008 02:05:19 -0800 (PST) Received: by 10.142.125.7 with HTTP; Mon, 10 Nov 2008 02:05:19 -0800 (PST) Message-ID: Date: Mon, 10 Nov 2008 18:05:19 +0800 To: internals@lists.php.net MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_95617_5411552.1226311519067" Subject: Trouble with Hashtable From: zhangsilly@gmail.com ("=?GB2312?B?1cXQxMHp?=") ------=_Part_95617_5411552.1226311519067 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline I am reading the Extending and Embedding PHP, but I account some errors with hashtable,even my code is actually the same as the sample code. I have codes like this: PHP_FUNCTION(wps_close) { FILE* fp; zval* file_handler; if(zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &file_handler) == FAILURE) { RETURN_FALSE; } ZEND_FETCH_RESOURCE(fp, FILE*, &file_handler, -1, PHP_WPS_HASH_DESCRIPTOR_RES_NAME, le_sample_descriptor); zend_hash_index_del(&EG(regular_list), Z_RESVAL_P(file_handler)); RETURN_TRUE; } the code above is just the same as the sample code except the variable name , which called file_resource in the sample and named file_handler in my code , i can't find more difference more than that. But the code above compile faild with visual studio 2008. It says: 1>wps_hash.c 1>..\..\..\wps_hash\wps_hash.c(149) : warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. 1> C:\Program Files\Microsoft Visual Studio 9.0\VC\include\stdio.h(237) : see declaration of 'fopen' 1>Linking... 1> Creating library C:\Documents and Settings\wps2000\Desktop\wps2000\wps_hash\Release\wps_hash.lib and object C:\Documents and Settings\wps2000\Desktop\wps2000\wps_hash\Release\wps_hash.exp 1>wps_hash.obj : error LNK2001: unresolved external symbol _executor_globals_id 1>C:\Documents and Settings\wps2000\Desktop\wps2000\wps_hash\Release\wps_hash.dll : fatal error LNK1120: 1 unresolved externals thanks ------=_Part_95617_5411552.1226311519067--