|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #21544 --with-mssql uses a lot of undeclared functions
Submitted: 2003-01-09 06:37 UTC Modified: 2004-04-14 22:23 UTC
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: php at dark-id dot de Assigned:
Status: Closed Package: MSSQL related
PHP Version: 4.3.0 OS: ANY
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: php at dark-id dot de
New email:
PHP Version: OS:


 [2003-01-09 06:37 UTC] php at dark-id dot de
compiling of php 4.3.0 terminates with
../php-4.3.0/ext/mssql/php_mssql.c: In function `zm_activate_mssql':
../php-4.3.0/ext/mssql/php_mssql.c:334: `SHORT' undeclared (first use in this function)
../php-4.3.0/ext/mssql/php_mssql.c:334: (Each undeclared identifier is reported only once
../php-4.3.0/ext/mssql/php_mssql.c:334: for each function it appears in.)

when configured with --with-mssql.

Any hints?


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-01-09 08:25 UTC]
It looks this happen because it uses by default /usr/local/freetds/ even if it doesn't exist. Not enough verifications on the config.m4...

 [2003-01-09 08:42 UTC]
Even with the latest freetds, it looks:
DBMSGHANDLE_PROC is not defined,
DBERRHANDLE is redefined,
DBSETOPT is redefined,
and dbsetopt hasn't got enough argument at line: 502,511,564,615,624.
 [2003-01-09 16:37 UTC]
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at
In case this was a documentation problem, the fix will show up soon at

In case this was a website problem, the change will show
up on the site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.

Extended checks for where FreeTDS is installed has been added to the configure script
 [2004-04-14 11:21 UTC]
This is still happening (or again happening) for me.
4.3.6RC3 (and CVS HEAD (4_3)).

Attached is a patch to fix this. I'm not a c guy, though, so please verify.



Index: ext/mssql/php_mssql.c
RCS file: /repository/php-src/ext/mssql/php_mssql.c,v
retrieving revision
diff -u -r1.86.2.31 php_mssql.c
--- ext/mssql/php_mssql.c       30 Mar 2004 17:54:38 -0000
+++ ext/mssql/php_mssql.c       14 Apr 2004 15:18:18 -0000
@@ -336,7 +336,7 @@
        if (MS_SQL_G(timeout) < 0) MS_SQL_G(timeout) = 60;
-       dbsetmaxprocs((SHORT)MS_SQL_G(max_procs));
+       dbsetmaxprocs((int)MS_SQL_G(max_procs));

        return SUCCESS;

 [2004-04-14 22:23 UTC]
Sean, open new report..and I think your patch is still wrong and your freetds installation is just broken.

PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Jul 20 00:01:03 2024 UTC