Sisyphus repositório
Última atualização: 1 outubro 2023 | SRPMs: 18631 | Visitas: 37045753
en ru br
ALT Linux repositórios
S:8.0.30-alt1
5.0: 5.1.4r1107-alt1
4.1: 3.51-alt1.1
4.0: 3.51-alt1.1

Group :: Sistema/Bibliotecas
RPM: mysql-connector-odbc

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs e FR  Repocop 

Patch: mysql-connector-odbc-8.0.13-fedora-myodbc-64bit.patch
Download


Fix some 64-bitness issues arising from unixODBC 2.2.14 changes.
diff --git a/driver/utility.cc b/driver/utility.cc
index 401a5e7..66765ed 100644
--- a/driver/utility.cc
+++ b/driver/utility.cc
@@ -1273,7 +1273,7 @@ SQLLEN fill_display_size_buff(char *buff, STMT *stmt, MYSQL_FIELD *field)
 {
   /* See comment for fill_transfer_oct_len_buff()*/
   SQLLEN size= get_display_size(stmt, field);
-  sprintf(buff,size == SQL_NO_TOTAL ? "%d" : (sizeof(SQLLEN) == 4 ? "%lu" : "%lld"), size);
+  sprintf(buff, (size == SQL_NO_TOTAL ? "%ld" : "%lu"), size);
 
   return size;
 }
@@ -1296,7 +1296,7 @@ SQLLEN fill_transfer_oct_len_buff(char *buff, STMT *stmt, MYSQL_FIELD *field)
   */
   SQLLEN len= get_transfer_octet_length(stmt, field);
 
-  sprintf(buff, len == SQL_NO_TOTAL ? "%d" : (sizeof(SQLLEN) == 4 ? "%lu" : "%lld"), len );
+  sprintf(buff, (len == SQL_NO_TOTAL ? "%ld" : "%lu"), len );
 
   return len;
 }
@@ -1313,8 +1313,7 @@ SQLLEN fill_transfer_oct_len_buff(char *buff, STMT *stmt, MYSQL_FIELD *field)
 SQLULEN fill_column_size_buff(char *buff, STMT *stmt, MYSQL_FIELD *field)
 {
   SQLULEN size= get_column_size(stmt, field);
-  sprintf(buff, (size== SQL_NO_TOTAL ? "%d" :
-      (sizeof(SQLULEN) == 4 ? "%lu" : "%llu")), size);
+  sprintf(buff, (size== SQL_NO_TOTAL ? "%ld" : "%lu"), size);
   return size;
 }
 
diff --git a/test/my_catalog1.c b/test/my_catalog1.c
index cee16ab..bf9aace 100644
--- a/test/my_catalog1.c
+++ b/test/my_catalog1.c
@@ -631,7 +631,7 @@ DECLARE_TEST(t_tables_bug)
     printMessage(" Column Name   : %s", szColName);
     printMessage(" NameLengh     : %d", pcbColName);
     printMessage(" DataType      : %d", pfSqlType);
-    printMessage(" ColumnSize    : %d", pcbColDef);
+    printMessage(" ColumnSize    : %ld", pcbColDef);
     printMessage(" DecimalDigits : %d", pibScale);
     printMessage(" Nullable      : %d", pfNullable);
 
 
projeto & código: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
mantenedor atual: Michael Shigorin
mantenedor da tradução: Fernando Martini aka fmartini © 2009