php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #15915 the sample code have some wrong on Creating Extensions
Submitted: 2002-03-06 15:46 UTC Modified: 2002-06-17 10:19 UTC
From: yorgo at 163 dot net Assigned:
Status: Closed Package: Documentation problem
PHP Version: 4.1.2 OS: linux
Private report: No CVE-ID: None
 [2002-03-06 15:46 UTC] yorgo at 163 dot net
http://www.php.net/manual/en/zend.creating.php

/* implement standard "stub" routine to introduce ourselves to Zend */
#if COMPILE_DL_FIRST_MODULE <-- this i think can change to #if COMPILE_DL
ZEND_GET_MODULE(firstmod)
#endif

/* implement function that is meant to be made available to PHP */
ZEND_FUNCTION(first_module)
{
    long parameter;

    if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &parameter) == FAILURE) {
        return;
    }

    RETURN_LONG(parmeter);
.                ^^^^^^ parameter
}

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-06-17 10:19 UTC] hholzgra@php.net
fixed in CVS
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Nov 19 20:00:01 2025 UTC