[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kexi/3.1] src/migration/mdb/3rdparty/mdbtools/libmdb: Revert "Avoid dynamic array allocation on sta
From:       Jaroslaw Staniek <null () kde ! org>
Date:       2018-09-03 14:51:06
Message-ID: E1fwqC2-0007mA-Gz () code ! kde ! org
[Download RAW message or body]

Git commit aab1e8f697f11ca8e02b4535aca358952924ab65 by Jaroslaw Staniek.
Committed on 03/09/2018 at 14:36.
Pushed by staniek into branch '3.1'.

Revert "Avoid dynamic array allocation on stack."

This reverts commit 1bc284de58f0b0e60c47cbebae10a4e36ed9380b.

(fix for non C99 compliant compiler - msvs)

M  +3    -2    src/migration/mdb/3rdparty/mdbtools/libmdb/money.c

https://commits.kde.org/kexi/aab1e8f697f11ca8e02b4535aca358952924ab65

diff --git a/src/migration/mdb/3rdparty/mdbtools/libmdb/money.c \
b/src/migration/mdb/3rdparty/mdbtools/libmdb/money.c index eaea04ae3..599e12664 \
                100644
--- a/src/migration/mdb/3rdparty/mdbtools/libmdb/money.c
+++ b/src/migration/mdb/3rdparty/mdbtools/libmdb/money.c
@@ -42,7 +42,8 @@ static char *array_to_string(unsigned char *array, int unsigned \
                scale, int neg);
  */
 char *mdb_money_to_string(MdbHandle *mdb, int start)
 {
-	const int num_bytes=8, scale=4;
+#define num_bytes 8
+	int scale=4;
 	int i;
 	int neg=0;
        unsigned char multiplier[MAX_NUMERIC_PRECISION], temp[MAX_NUMERIC_PRECISION];
@@ -79,7 +80,7 @@ char *mdb_money_to_string(MdbHandle *mdb, int start)
 }
 
 char *mdb_numeric_to_string(MdbHandle *mdb, int start, int prec, int scale) {
-       const int num_bytes = 16;
+#define num_bytes 16
        int i;
        int neg=0;
        unsigned char multiplier[MAX_NUMERIC_PRECISION], temp[MAX_NUMERIC_PRECISION];


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic