]> granicus.if.org Git - php/commitdiff
format string fixes
authorAndrey Hristov <andrey@php.net>
Thu, 28 Aug 2003 21:00:24 +0000 (21:00 +0000)
committerAndrey Hristov <andrey@php.net>
Thu, 28 Aug 2003 21:00:24 +0000 (21:00 +0000)
ext/db/db.c
ext/dbase/dbase.c
ext/filepro/filepro.c
ext/gd/gd.c
ext/msql/php_msql.c
ext/mssql/php_mssql.c
ext/mysqli/mysqli_api.c
ext/odbc/birdstep.c
ext/pgsql/pgsql.c
ext/pspell/pspell.c
ext/sybase/php_sybase_db.c

index db6cde12c76b1c66e6b816df7458cbcb552e6a9c..d4f261b5417ecd9242f6ddc2cc5f44827d27f986 100644 (file)
@@ -505,7 +505,7 @@ PHP_FUNCTION(dbminsert)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
        
@@ -531,7 +531,7 @@ PHP_FUNCTION(dbmreplace)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
        
@@ -599,7 +599,7 @@ PHP_FUNCTION(dbmfetch)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
 
@@ -675,7 +675,7 @@ PHP_FUNCTION(dbmexists)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
 
@@ -724,7 +724,7 @@ PHP_FUNCTION(dbmdelete)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
 
@@ -771,7 +771,7 @@ PHP_FUNCTION(dbmfirstkey)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
 
@@ -833,7 +833,7 @@ PHP_FUNCTION(dbmnextkey)
 
        info = php_find_dbm(id TSRMLS_CC);
        if (!info) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %d", Z_LVAL_P(id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid database identifier %ld", Z_LVAL_P(id));
                RETURN_FALSE;
        }
 
index cc2512586026e72fd777bbc6c958eeae1e8a0f0b..54434fb701c78eb117808369538f5c3a71d844ac 100644 (file)
@@ -163,7 +163,7 @@ PHP_FUNCTION(dbase_close)
        convert_to_long_ex(dbh_id);
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
@@ -187,7 +187,7 @@ PHP_FUNCTION(dbase_numrecords)
        convert_to_long_ex(dbh_id);
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
@@ -210,7 +210,7 @@ PHP_FUNCTION(dbase_numfields)
        convert_to_long_ex(dbh_id);
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
@@ -233,7 +233,7 @@ PHP_FUNCTION(dbase_pack)
        convert_to_long_ex(dbh_id);
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
@@ -268,7 +268,7 @@ PHP_FUNCTION(dbase_add_record)
 
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
@@ -339,7 +339,7 @@ PHP_FUNCTION(dbase_replace_record)
 
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
@@ -395,15 +395,15 @@ PHP_FUNCTION(dbase_delete_record)
 
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
        if (del_dbf_record(dbh, Z_LVAL_PP(record)) < 0) {
                if (Z_LVAL_PP(record) > dbh->db_records) {
-                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "record %d out of bounds", Z_LVAL_PP(record));
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "record %ld out of bounds", Z_LVAL_PP(record));
                } else {
-                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to delete record %d", Z_LVAL_PP(record));
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to delete record %ld", Z_LVAL_PP(record));
                }
                RETURN_FALSE;
        }
@@ -435,12 +435,12 @@ static void php_dbase_get_record(INTERNAL_FUNCTION_PARAMETERS, int assoc)
 
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
        if ((data = get_dbf_record(dbh, Z_LVAL_PP(record))) == NULL) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Tried to read bad record %d", Z_LVAL_PP(record));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Tried to read bad record %ld", Z_LVAL_PP(record));
                RETURN_FALSE;
        }
 
@@ -760,7 +760,7 @@ PHP_FUNCTION(dbase_get_header_info)
 
        dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type);
        if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %d", Z_LVAL_PP(dbh_id));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id));
                RETURN_FALSE;
        }
 
index 495344783491f9e6d9557f8ea373b52ed33fbc24..b5e9ec986cc880ddaf43ee4cffc483cd1a00fde8 100644 (file)
@@ -375,7 +375,7 @@ PHP_FUNCTION(filepro_fieldname)
                }
        }
 
-       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to locate field number %d.", Z_LVAL_PP(fno));
+       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to locate field number %ld.", Z_LVAL_PP(fno));
 
        RETVAL_FALSE;
 }
@@ -412,7 +412,7 @@ PHP_FUNCTION(filepro_fieldtype)
                        RETURN_STRING(lp->format, 1);
                }
        }
-       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to locate field number %d.", Z_LVAL_PP(fno));
+       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to locate field number %ld.", Z_LVAL_PP(fno));
        RETVAL_FALSE;
 }
 /* }}} */
@@ -448,7 +448,7 @@ PHP_FUNCTION(filepro_fieldwidth)
                        RETURN_LONG(lp->width);
                }
        }
-       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to locate field number %d.", Z_LVAL_PP(fno));
+       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to locate field number %ld.", Z_LVAL_PP(fno));
        RETVAL_FALSE;
 }
 /* }}} */
index 8b8d8aa97470ae98a1512f1dddcb81513098a1e3..1352255aa1a27a747c901753eab681e8c100f80c 100644 (file)
@@ -3247,7 +3247,7 @@ PHP_FUNCTION(imagepscopyfont)
        of_ind = zend_list_find(Z_LVAL_PP(fnt), &type);
 
        if (type != le_ps_font) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a Type 1 font index", Z_LVAL_PP(fnt));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a Type 1 font index", Z_LVAL_PP(fnt));
                RETURN_FALSE;
        }
 
index 9ccacaab848247430076d3bb62ac5a58f71b7394..6acb51d35ed31dc09bf2aeedbc7e7633cdfff7d2 100644 (file)
@@ -786,7 +786,7 @@ PHP_FUNCTION(msql_result)
        
        convert_to_long(row);
        if (Z_LVAL_P(row)<0 || Z_LVAL_P(row)>=msqlNumRows(msql_result)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %d on mSQL query index %d",Z_LVAL_P(row),Z_LVAL_P(result));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %ld on mSQL query index %ld", Z_LVAL_P(row), Z_LVAL_P(result));
                RETURN_FALSE;
        }
        msqlDataSeek(msql_result,Z_LVAL_P(row));
@@ -818,7 +818,7 @@ PHP_FUNCTION(msql_result)
                                                i++;
                                        }
                                        if (!tmp_field) { /* no match found */
-                                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s%s%s not found in mSQL query index %d",
+                                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s%s%s not found in mSQL query index %ld",
                                                                        (table_name?table_name:""), (table_name?".":""), field_name, Z_LVAL_P(result));
                                                efree(field_name);
                                                if (table_name) {
@@ -1010,7 +1010,7 @@ PHP_FUNCTION(msql_data_seek)
        if (!msql_result ||
                        Z_LVAL_P(offset)<0 || 
                        Z_LVAL_P(offset)>=msqlNumRows(msql_result)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is invalid for mSQL query index %d",Z_LVAL_P(offset),Z_LVAL_P(result));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is invalid for mSQL query index %ld", Z_LVAL_P(offset), Z_LVAL_P(result));
                RETURN_FALSE;
        }
        msqlDataSeek(msql_result,Z_LVAL_P(offset));
@@ -1128,7 +1128,7 @@ PHP_FUNCTION(msql_field_seek)
                RETURN_FALSE;
        }
        if (Z_LVAL_P(offset)<0 || Z_LVAL_P(offset)>=msqlNumFields(msql_result)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING,"Field %d is invalid for mSQL query index %d",
+               php_error_docref(NULL TSRMLS_CC, E_WARNING,"Field %ld is invalid for mSQL query index %ld",
                                Z_LVAL_P(offset),Z_LVAL_P(result));
                RETURN_FALSE;
        }
@@ -1162,7 +1162,7 @@ static void php_msql_field_info(INTERNAL_FUNCTION_PARAMETERS, int entry_type)
        }
        convert_to_long(field);
        if (Z_LVAL_P(field)<0 || Z_LVAL_P(field)>=msqlNumFields(msql_result)) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING,"Field %d is invalid for mSQL query index %d",Z_LVAL_P(field),Z_LVAL_P(result));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING,"Field %ld is invalid for mSQL query index %ld", Z_LVAL_P(field), Z_LVAL_P(result));
                RETURN_FALSE;
        }
        msqlFieldSeek(msql_result,Z_LVAL_P(field));
index 65b0a86ca2975d1acee57f0ff4ea5aab16e9e6f4..64c562d8b4059e9e844543d83250f4aab5d3a5fa 100644 (file)
@@ -1726,7 +1726,7 @@ PHP_FUNCTION(mssql_result)
        
        convert_to_long_ex(row);
        if (Z_LVAL_PP(row) < 0 || Z_LVAL_PP(row) >= result->num_rows) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad row offset (%d)", Z_LVAL_PP(row));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad row offset (%ld)", Z_LVAL_PP(row));
                RETURN_FALSE;
        }
 
index cf96ceccb50b69c8ae804c21853e16a9a62490ee..94a16f20dc1c1b2fd236fb66816cc3e1e717ede4 100644 (file)
@@ -173,7 +173,7 @@ PHP_FUNCTION(mysqli_bind_param)
                                break;
 
                        default:
-                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Undefined fieldtype %d (parameter %d)", Z_LVAL_PP(args[i]), i+1);
+                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Undefined fieldtype %ld (parameter %d)", Z_LVAL_PP(args[i]), i+1);
                                efree(args);
                                efree(bind);
                                RETURN_FALSE; 
index db274d92c5eafd3cd65dda5b8e7c7be8e12768dc..050ff8b7511ccbe8d8772b767219eaaf66a50b23 100644 (file)
@@ -103,8 +103,8 @@ ZEND_GET_MODULE(birdstep)
 THREAD_LS birdstep_module php_birdstep_module;
 THREAD_LS static HENV henv;
 
-#define PHP_GET_BIRDSTEP_RES_IDX(id) convert_to_long_ex(id); if (!(res = birdstep_find_result(list, Z_LVAL_PP(id)))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Birdstep: Not result index (%d)", Z_LVAL_PP(id)); RETURN_FALSE; } 
-#define PHP_BIRDSTEP_CHK_LNK(id) convert_to_long_ex(id); if (!(conn = birdstep_find_conn(list,Z_LVAL_PP(id)))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Birdstep: Not connection index (%d)", Z_LVAL_PP(id)); RETURN_FALSE; }
+#define PHP_GET_BIRDSTEP_RES_IDX(id) convert_to_long_ex(id); if (!(res = birdstep_find_result(list, Z_LVAL_PP(id)))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Birdstep: Not result index (%ld)", Z_LVAL_PP(id)); RETURN_FALSE; } 
+#define PHP_BIRDSTEP_CHK_LNK(id) convert_to_long_ex(id); if (!(conn = birdstep_find_conn(list,Z_LVAL_PP(id)))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Birdstep: Not connection index (%ld)", Z_LVAL_PP(id)); RETURN_FALSE; }
                                                         
 
 static void _close_birdstep_link(zend_rsrc_list_entry *rsrc TSRMLS_DC)
index 9d0f57e704e553d22102c4c35ffa9511bf26984a..58737b99cb4896a513d31cd1c1930938de513a42 100644 (file)
@@ -1364,7 +1364,8 @@ PHP_FUNCTION(pg_fetch_result)
                convert_to_long_ex(row);
                pgsql_row = Z_LVAL_PP(row);
                if (pgsql_row < 0 || pgsql_row >= PQntuples(pgsql_result)) {
-                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %d on PostgreSQL result index %d", Z_LVAL_PP(row), Z_LVAL_PP(result));
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %ld on PostgreSQL result index %ld",
+                                                       Z_LVAL_PP(row), Z_LVAL_PP(result));
                        RETURN_FALSE;
                }
        }
@@ -1447,7 +1448,8 @@ static void php_pgsql_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, int result_type)
                        pgsql_row = Z_LVAL_PP(row);
                        pg_result->row = pgsql_row;
                        if (pgsql_row < 0 || pgsql_row >= PQntuples(pgsql_result)) {
-                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %d on PostgreSQL result index %d", Z_LVAL_PP(row), Z_LVAL_PP(result));
+                               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %ld on PostgreSQL result index %ld",
+                                                               Z_LVAL_PP(row), Z_LVAL_PP(result));
                                RETURN_FALSE;
                        }
                } else {
@@ -1623,7 +1625,8 @@ static void php_pgsql_data_info(INTERNAL_FUNCTION_PARAMETERS, int entry_type)
                convert_to_long_ex(row);
                pgsql_row = Z_LVAL_PP(row);
                if (pgsql_row < 0 || pgsql_row >= PQntuples(pgsql_result)) {
-                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %d on PostgreSQL result index %d", Z_LVAL_PP(row), Z_LVAL_PP(result));
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to jump to row %ld on PostgreSQL result index %ld",
+                                                       Z_LVAL_PP(row), Z_LVAL_PP(result));
                        RETURN_FALSE;
                }
        }
@@ -2139,11 +2142,12 @@ PHP_FUNCTION(pg_lo_write)
        if (argc > 2) {
                convert_to_long_ex(z_len);
                if (Z_LVAL_PP(z_len) > Z_STRLEN_PP(str)) {
-                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot write more than buffer size %d. Tried to write %d", Z_LVAL_PP(str), Z_LVAL_PP(z_len));
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot write more than buffer size %d. Tried to write %ld", 
+                                                       Z_STRLEN_PP(str), Z_LVAL_PP(z_len));
                        RETURN_FALSE;
                }
                if (Z_LVAL_PP(z_len) < 0) {
-                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Buffer size must be larger than 0, but %d was specified", Z_LVAL_PP(str), Z_LVAL_PP(z_len));
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Buffer size must be larger than 0, but %d was specified", Z_STRLEN_PP(str));
                        RETURN_FALSE;
                }
                len = Z_LVAL_PP(z_len);
index 94745b9f9173e78da0dfcae595661aa9e3601afe..72c8af7e35a9a321dec25eaeb6a673a39e3d7c11 100644 (file)
@@ -354,7 +354,7 @@ PHP_FUNCTION(pspell_new_config)
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(conf), &type);
        
        if (config == NULL || type != le_pspell_config) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index", Z_LVAL_PP(conf));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(conf));
                RETURN_FALSE;
        }
 
@@ -389,7 +389,7 @@ PHP_FUNCTION(pspell_check)
        convert_to_string_ex(word);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
                RETURN_FALSE;
        }
 
@@ -421,7 +421,7 @@ PHP_FUNCTION(pspell_suggest)
        convert_to_string_ex(word);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
        RETURN_FALSE;
        }
 
@@ -460,7 +460,7 @@ PHP_FUNCTION(pspell_store_replacement)
        convert_to_string_ex(corr);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
                RETURN_FALSE;
        }
 
@@ -492,7 +492,7 @@ PHP_FUNCTION(pspell_add_to_personal)
        convert_to_string_ex(word);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
                RETURN_FALSE;
        }
 
@@ -529,7 +529,7 @@ PHP_FUNCTION(pspell_add_to_session)
        convert_to_string_ex(word);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
                RETURN_FALSE;
        }
 
@@ -565,7 +565,7 @@ PHP_FUNCTION(pspell_clear_session)
        convert_to_long_ex(scin);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
                RETURN_FALSE;
        }
 
@@ -596,7 +596,7 @@ PHP_FUNCTION(pspell_save_wordlist)
        convert_to_long_ex(scin);
        manager = (PspellManager *) zend_list_find(Z_LVAL_PP(scin), &type);
        if(!manager){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL result index",Z_LVAL_PP(scin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL result index", Z_LVAL_PP(scin));
                RETURN_FALSE;
        }
 
@@ -679,7 +679,7 @@ PHP_FUNCTION(pspell_config_runtogether)
        convert_to_long_ex(sccin);
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(sccin), &type);
        if(!config){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index",Z_LVAL_PP(sccin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(sccin));
                RETURN_FALSE;
        }
 
@@ -708,7 +708,7 @@ PHP_FUNCTION(pspell_config_mode)
        convert_to_long_ex(sccin);
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(sccin), &type);
        if(!config){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index",Z_LVAL_PP(sccin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(sccin));
                RETURN_FALSE;
        }
 
@@ -749,7 +749,7 @@ PHP_FUNCTION(pspell_config_ignore)
        convert_to_long_ex(sccin);
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(sccin), &type);
        if(!config){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index",Z_LVAL_PP(sccin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(sccin));
                RETURN_FALSE;
        }
 
@@ -795,7 +795,7 @@ PHP_FUNCTION(pspell_config_personal)
        convert_to_long_ex(sccin);
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(sccin), &type);
        if(!config){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index",Z_LVAL_PP(sccin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(sccin));
                RETURN_FALSE;
        }
 
@@ -833,7 +833,7 @@ PHP_FUNCTION(pspell_config_repl)
        convert_to_long_ex(sccin);
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(sccin), &type);
        if(!config){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index",Z_LVAL_PP(sccin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(sccin));
                RETURN_FALSE;
        }
 
@@ -873,7 +873,7 @@ PHP_FUNCTION(pspell_config_save_repl)
        convert_to_long_ex(sccin);
        config = (PspellConfig *) zend_list_find(Z_LVAL_PP(sccin), &type);
        if(!config){
-               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%d is not a PSPELL config index",Z_LVAL_PP(sccin));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a PSPELL config index", Z_LVAL_PP(sccin));
                RETURN_FALSE;
        }
 
index b2eed1c88d804d7a87a9adfd5df455e2fa19b10c..40f09dd427aecc66da982a5e638e4199f1775589 100644 (file)
@@ -957,7 +957,7 @@ PHP_FUNCTION(sybase_free_result)
        result = (sybase_result *) zend_list_find(Z_LVAL_PP(sybase_result_index),&type);
        
        if (type!=php_sybase_module.le_result) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING,"%d is not a Sybase result index",Z_LVAL_PP(sybase_result_index));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a Sybase result index", Z_LVAL_PP(sybase_result_index));
                RETURN_FALSE;
        }
        zend_list_delete(Z_LVAL_PP(sybase_result_index));
@@ -1078,7 +1078,7 @@ static void php_sybase_fetch_hash(INTERNAL_FUNCTION_PARAMETERS)
        result = (sybase_result *) zend_list_find(Z_LVAL_PP(sybase_result_index),&type);
        
        if (type!=php_sybase_module.le_result) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING,"%d is not a Sybase result index",Z_LVAL_PP(sybase_result_index));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "%ld is not a Sybase result index", Z_LVAL_PP(sybase_result_index));
                RETURN_FALSE;
        }
        
@@ -1314,7 +1314,7 @@ PHP_FUNCTION(sybase_result)
        
        convert_to_long_ex(row);
        if (Z_LVAL_PP(row)<0 || Z_LVAL_PP(row)>=result->num_rows) {
-               php_error_docref(NULL TSRMLS_CC, E_WARNING,"Sybase:  Bad row offset (%d)",Z_LVAL_PP(row));
+               php_error_docref(NULL TSRMLS_CC, E_WARNING,"Sybase:  Bad row offset (%ld)", Z_LVAL_PP(row));
                RETURN_FALSE;
        }