]> granicus.if.org Git - php/commitdiff
MFH
authorIlia Alshanetsky <iliaa@php.net>
Wed, 12 Feb 2003 20:44:26 +0000 (20:44 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Wed, 12 Feb 2003 20:44:26 +0000 (20:44 +0000)
ext/fbsql/php_fbsql.c
main/snprintf.c

index 75a6e14b98459df795157ebfe8644b0a39010d8f..fda842e7bf818f116d2e491b9da69819a58bd733 100644 (file)
@@ -2275,7 +2275,7 @@ void phpfbColumnAsString(PHPFBResult* result, int column, void* data , int* leng
                        phpfbestrdup(b, length, value);
                }
                break;
-
+#ifdef FB_TinyInteger
                case FB_TinyInteger:
                { 
                        short int   v = *((short int*)data);
@@ -2284,7 +2284,8 @@ void phpfbColumnAsString(PHPFBResult* result, int column, void* data , int* leng
                        phpfbestrdup(b, length, value);
                }
                break;
-
+#endif
+#ifdef FB_LongInteger
                case FB_LongInteger:
                { 
                        FBLongInteger v = *((FBLongInteger*)data);
@@ -2297,7 +2298,7 @@ void phpfbColumnAsString(PHPFBResult* result, int column, void* data , int* leng
                        phpfbestrdup(b, length, value);
                }
                break;
-
+#endif
                case FB_SmallInteger:
                {
                        short v = *((short*)data);
index a8f7d75f605958dce97993ce03aadfb6a47e5953..fa5a07cc45a6a3c43d0a432e9a8dabe4e36c848f 100644 (file)
@@ -298,7 +298,7 @@ ap_php_cvt(double arg, int ndigits, int *decpt, int *sign, int eflag, char *buf)
                while (p1 < &buf[NDIG])
                        *p++ = *p1++;
        } else if (arg > 0) {
-               while ((fj = arg * 10) < 1) {
+               while ((fj = arg * 10) < 1 && (r2 * -1) < ndigits) {
                        arg = fj;
                        r2--;
                }