[PHP-DEV] php-4.3.2RC1 interbase/firebird config.m4 problem

2003-03-15 Thread Daniela Mariaschi
Let's spend few words about Firebird first.
Firebird it's a fork of Interbase 6.0 source code, and its development is
managed by a team of independent developers, not from Borland itself.
Only Interbase 6.0  has been  released as open source code 
instead Firebird is an open source project .
you can find more at  http://firebird.sourceforge.net.
Right now both Interbase and Firebird have same API calls
and php interbase module it's working for Firebird too.
(May be in the future they will have different development .)

Now, the problem with php-4.3.2RC1 (and current CVS too)
tested on  Debian Woody and RH7.3  with Firebird instead of Interbase

=
./configure --with-interbase=/usr

configure:37403: checking for InterBase support
configure:37461: checking for isc_detach_database in -lgds
configure:37480: gcc -o conftest -g -O2
-L/usr/lib -lgds
conftest.c -lgds  -lresolv -lm -ldl -lnsl  15
/usr/lib/libgds.so: undefined reference to `crypt'
collect2: ld returned 1 exit status
configure: failed program was:
#line 37469 configure
#include confdefs.h
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply.  */
char isc_detach_database();

int main() {
isc_detach_database()
; return 0; }
=

with Firebird we need libcrypt while testing for libgds .
but as Jani noticed ... can we be 100% sure libcrypt  is always available?
...mmmhhh
I saw  test for libgds was added in response of  bug #21977 and
for Interbase users this is ok but Firebird  users can't correctly compile
php .
any suggestion is really appreciated  

Daniela


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-DEV] Interbase blob stream broken!

2002-09-30 Thread Daniela Mariaschi

Testing for  bug #18964 (a win32 related bug in PHP 4.2.0 )
I saw that  InterBase module in version 4.3 works with new features of PHP
stream,
and I  found out  that  now ANY  calls  to ibase_blob_import()  fails on
Linux  too.
I 've tried with older version of PHP (4.1.2/4.2.x) and  there are no
problems
Could someone  (possibly Wez)  have a look please?

Hope I' m wrong ...
Daniela



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] Re: Bug #17184: Interbase 5.1.1.682 compilation

2002-05-14 Thread Daniela Mariaschi

Hi,

Some  functions added in interbase module raise compiler error.
these functions require IB 6 or later cause they work together with the new
IB6 API.

It seems as in the code there is no control on  the IB version installed,
and the compiler is always  looking for new Api .
People who are using an IB version  6 can't compile the source ...
This can be fix in CVS ... but  what about  release?

-Daniela

- Original Message -
From: [EMAIL PROTECTED]
Newsgroups: php.bugs
To: [EMAIL PROTECTED]
Sent: Monday, May 13, 2002 5:48 PM
Subject: Bug #17184: Interbase 5.1.1.682 compilation


 From: [EMAIL PROTECTED]
 Operating system: Linux 2.4.7-10
 PHP version:  4.2.0
 PHP Bug Type: Compile Failure
 Bug description:  Interbase 5.1.1.682 compilation

 Get error on make when trying to compile with
 '--with-interbase=/usr/interbase'.

 Worked fine with php-4.1.2

 I get the following error :


 gcc -I. -I/usr/local/php/ext/interbase -I/usr/local/php/main
 -I/usr/local/php -I/usr/local/apache_1.3.22/src/include
 -I/usr/local/apache_1.3.22/src/os/unix -I/usr/local/php/Zend
 -I/usr/local/openssl/include -I/include -I/usr/local/include
 -I/usr/include/imap -I/usr/interbase/include -I/usr/include/mysql
 -I/usr/local/php/ext/xml/expat  -I/usr/local/php/TSRM -g -O2  -c
 interbase.c  touch interbase.lo
 interbase.c: In function `_php_ibase_user':
 interbase.c:2977: `isc_action_svc_add_user' undeclared (first use in this
 function)
 interbase.c:2977: (Each undeclared identifier is reported only once
 interbase.c:2977: for each function it appears in.)
 interbase.c:2978: `isc_action_svc_modify_user' undeclared (first use in
 this function)
 interbase.c:2985: `isc_action_svc_delete_user' undeclared (first use in
 this function)
 interbase.c:2980: warning: unreachable code at beginning of switch
 statement
 interbase.c:3041: `isc_spb_version' undeclared (first use in this
 function)
 interbase.c:3042: `isc_spb_current_version' undeclared (first use in this
 function)
 interbase.c:3068: `isc_spb_sec_username' undeclared (first use in this
 function)
 interbase.c:3074: `isc_spb_sec_password' undeclared (first use in this
 function)
 interbase.c:3081: `isc_spb_sec_firstname' undeclared (first use in this
 function)
 interbase.c:3088: `isc_spb_sec_middlename' undeclared (first use in this
 function)
 interbase.c:3095: `isc_spb_sec_lastname' undeclared (first use in this
 function)
 interbase.c: In function `zif_ibase_add_user':
 interbase.c:3123: `isc_action_svc_add_user' undeclared (first use in this
 function)
 interbase.c: In function `zif_ibase_modify_user':
 interbase.c:3132: `isc_action_svc_modify_user' undeclared (first use in
 this function)
 interbase.c: In function `zif_ibase_delete_user':
 interbase.c:3140: `isc_action_svc_delete_user' undeclared (first use in
 this function)
 make[3]: *** [interbase.lo] Error 1
 make[3]: Leaving directory `/usr/local/php-4.2.0/ext/interbase'
 make[2]: *** [all-recursive] Error 1
 make[2]: Leaving directory `/usr/local/php-4.2.0/ext/interbase'
 make[1]: *** [all-recursive] Error 1
 make[1]: Leaving directory `/usr/local/php-4.2.0/ext'
 make: *** [all-recursive] Error 1

 Thx

 Per MÃ¥rtensson




 --
 Edit bug report at http://bugs.php.net/?id=17184edit=1
 --
 Fixed in CVS:http://bugs.php.net/fix.php?id=17184r=fixedcvs
 Fixed in release:http://bugs.php.net/fix.php?id=17184r=alreadyfixed
 Need backtrace:  http://bugs.php.net/fix.php?id=17184r=needtrace
 Try newer version:   http://bugs.php.net/fix.php?id=17184r=oldversion
 Not developer issue: http://bugs.php.net/fix.php?id=17184r=support
 Expected behavior:   http://bugs.php.net/fix.php?id=17184r=notwrong
 Not enough info: http://bugs.php.net/fix.php?id=17184r=notenoughinfo
 Submitted twice: http://bugs.php.net/fix.php?id=17184r=submittedtwice
 register_globals:http://bugs.php.net/fix.php?id=17184r=globals



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] Interbase bug #15419 - #15992 (proposal)

2002-04-02 Thread Daniela Mariaschi

EXTENSION:   interbase
PRIMARY MAINTAINER:  Jouni Ahto
MAINTENANCE: Odd Fixes
STATUS:  Working

Hello Jouni ,

Following up from bug #15419 and #15992
I finally :)  found a  (good ?) solution to avoid  segmentation fault 
so, I would like to let you know about the way I thought to fix it.

Actually, the problem lies in resources release during  shutdown process
if a user close a connection without  explicitly specify to release its
query or resultset  
Sigfault is due to the calling to an IB Api  when  DB is already
closed.  This calling  raise an error . but the buffer (global) to
handle the error message is already released too ... crash

I think we can solve  this, in two different ways:
1) it would be possible to skip the raise error  step... but it doesn't seem
to me the correct way to solve the problem .
or
2) it would be  possible to test if we have the relative transaction open.
... if so ... then we can proceed to release the statement 
otherwise  we have nothing to do .

I 've choosen this second way in the patch (see attach)
If you have no objections ... I 'm going to commit this  patch in CVS,
or let me  know your opinion , any suggestion is really appreciated
..

Daniela














Bug15419.diff
Description: Binary data

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP-DEV] Re: [PHP-CVS] cvs: php4 /ext/interbase interbase.c

2002-03-21 Thread Daniela Mariaschi


 On Tue, 19 Mar 2002, Ludovico Magnocavallo wrote:
  Derick Daniela patch allows tests 3-6 in ext/interbase/tests to pass

 Ah okay. Can you also make sure the patches go into yhe PHP_4_2_0 branch
 so that they are available in the new PHP CVS release?

 Derick


Hello Derick, sorry for my delay ...

ok,  I will commit that fix on rendering numeric/decimal number on the
PHP_4_2_0 branch
in the afternoon  as soon as possible ...

I would like to ask you if  I have also  to commit in PHP_4_2_0 the new
function
ibase_fetch_assoc  I committed last week  or  if   it's better according to
you  to postpon it.

Daniela



  [EMAIL PROTECTED] wrote in message

  news:[EMAIL PROTECTED]...
   Hello Daniela,
  
   I thought that I fixed it already:
  
   http://news.php.net/article.php?group=php.cvsarticle=9742
  
   And you reverted now this note (from the same bug):
  
  [6 Mar 6:21am] [EMAIL PROTECTED]
   Hi; I am the original fixer...
   Noticed that
  
   for (i = 0; i  -scale; i++)
   number /= 10;
  
   can be substituted with
  
   number /= - 10 *  scale;
  
   with a boost on performance. (remember that interbase
   stores the scale as a negative number).
  
  
   can you have a look at it?
  
  
   Derick
  
  
   On Tue, 19 Mar 2002, Daniela Mariaschi wrote:
  
daniela Tue Mar 19 10:29:18 2002 EDT
   
  Modified files:
/php4/ext/interbase interbase.c
  Log:
  fixed floating number incorrectly rendered (as mentioned by
  [EMAIL PROTECTED] in BUG #14755)
   
Index: php4/ext/interbase/interbase.c
diff -u php4/ext/interbase/interbase.c:1.80
  php4/ext/interbase/interbase.c:1.81
--- php4/ext/interbase/interbase.c:1.80 Sat Mar 16 13:43:41 2002
+++ php4/ext/interbase/interbase.c Tue Mar 19 10:29:17 2002
@@ -17,7 +17,7 @@
   
  +--+
  */
   
-/* $Id: interbase.c,v 1.80 2002/03/16 18:43:41 wez Exp $ */
+/* $Id: interbase.c,v 1.81 2002/03/19 15:29:17 daniela Exp $ */
   
   
 /* TODO: Arrays, roles?
@@ -595,7 +595,7 @@
   
 php_info_print_table_start();
 php_info_print_table_row(2, Interbase Support, enabled);
- php_info_print_table_row(2, Revision, $Revision: 1.80 $);
+ php_info_print_table_row(2, Revision, $Revision: 1.81 $);
 #ifdef COMPILE_DL_INTERBASE
 php_info_print_table_row(2, Dynamic Module, yes);
 #endif
@@ -1787,13 +1787,14 @@
 val-type = IS_STRING;
   
 if (scale) {
- int i, len;
- char dt[20];
+ int j, f = 1;
 double number = (double) ((ISC_INT64) (*((ISC_INT64 *)data)));
-
- number /= - 10 * scale;
+ char dt[20];
+ for (j = 0; j  -scale; j++) {
+ f *= 10;
+ }
 sprintf(dt, %%0.%df, -scale);
- val-value.str.len = sprintf (string_data, dt, number);
+ val-value.str.len = sprintf (string_data, dt, number/f );
 } else {
 val-value.str.len = sprintf (string_data, %Ld,
 (ISC_INT64) (*((ISC_INT64 *)data)));
   
   




-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] number fix on interbase.c

2002-03-19 Thread Daniela Mariaschi

Hey,

Using  latest.tar.gz  I found out that DECIMAL/NUMERIC values
don' t display correctly because of this instruciton:
number /= - 10 * scale;
I correct it and already committed on CVS cause it was
a really serious bug .

Any objection?

Daniela



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] stream and interbase don't compile

2002-03-16 Thread Daniela Mariaschi

Hey Wez 
could you please  check the interbase module ?

I receive this error with  today CVS source and latest.tar.gz too :
/php4/ext/interbase/interbase.c: In function `zif_ibase_blob_import':
/php4/ext/interbase/interbase.c:2919: too many arguments to function
`php_stream_read'
make: *** [ext/interbase/interbase.lo] Error 1

I can change it but I think it's better if  you  make it, isn't it?

Daniela







-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] interbase.c new function

2002-03-13 Thread Daniela Mariaschi

In response to bug #15602 (for which I already submitted a patch for NULL
fields last week), I have developed a new function for the Interbase module,
ibase_fetch_assoc that returns a row from a query result as a hash.

I am attaching the patches to this message.

As a side note, I have a few other fixes/additions to the interbase module
that I will submit in the next few days, should I ask for a CVS account so
that I can commit them without resorting to the list every time?

Thanks

Daniela


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] interbase.c new function (patch files)

2002-03-13 Thread Daniela Mariaschi

forgot the attachments.

Daniela



patch_interbase.c
Description: Binary data


patch_interbase.h
Description: Binary data

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP-DEV] CVS Account Request: daniela

2002-03-13 Thread Daniela Mariaschi

Committing bug fixes and additions to the interbase module without resorting to the 
kind people at php-dev every time.

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DEV] Interbase module patch

2002-03-01 Thread Daniela Mariaschi

Following up from bug #15602, I have written a patch to return NULL and
empty fields from ibase_fetch_row() and ibase_fetch_object()

The current implementation of those two functions skips (ignores) empty or
NULL fields, returning rows of different lenghts in a result set, depending
of the number of NULL fields in each row

Daniela Mariaschi

Index: interbasec
===
RCS file: /repository/php4/ext/interbase/interbasec,v
retrieving revision 175
diff -r175 interbasec
2109c2109
 break;
---
   break;
2119c2119,2125
   } /* if not null */
---
   } else {
   if (fetch_type  FETCH_ARRAY) {
   add_index_null(return_value, i);
   } else {
   add_property_null(return_value,
var-aliasname);
   }
   }




-- 
PHP Development Mailing List http://wwwphpnet/
To unsubscribe, visit: http://wwwphpnet/unsubphp