summaryrefslogtreecommitdiff
path: root/databases/mdbtools
diff options
context:
space:
mode:
authorMikhail Teterin <mi@FreeBSD.org>2003-04-15 16:35:53 +0000
committerMikhail Teterin <mi@FreeBSD.org>2003-04-15 16:35:53 +0000
commitfe49eb69706f1d016a33549a904ad7e347a20633 (patch)
treef5b10a05f260981b84bd6f6fe856acdba6079fff /databases/mdbtools
parentReally fix this port. Make it depend on libgnomeui if present, and (diff)
Add a patch found in the SourceForge page of this project.
No REVISION bump, since the port was not building until 10 minutes ago.
Notes
Notes: svn path=/head/; revision=79017
Diffstat (limited to 'databases/mdbtools')
-rw-r--r--databases/mdbtools/files/patch-jet4rows33
1 files changed, 33 insertions, 0 deletions
diff --git a/databases/mdbtools/files/patch-jet4rows b/databases/mdbtools/files/patch-jet4rows
new file mode 100644
index 000000000000..1471751e3333
--- /dev/null
+++ b/databases/mdbtools/files/patch-jet4rows
@@ -0,0 +1,33 @@
+This patch was downloaded from SourceForge, to which it was submitted
+Matt <mws at rochester.rr.com>, who wrote:
+
+ This patch fixes the Jet4 tab_num_rows_offset constant
+ and changes mdb_read_row so it checks the row number
+ against the number of rows in the table.
+
+ I have some MDB files for which the normal logic in
+ mdb_read_row fails. This patch solves the problem.
+
+--- src/libmdb/data.c 2003-01-12 17:59:43.000000000 -0500
++++ src/libmdb/data.c 2003-01-23 14:42:57.000000000 -0500
+@@ -171,6 +171,9 @@
+ unsigned char null_mask[33]; /* 256 columns max / 8 bits per byte */
+ unsigned char isnull;
+
++ if (table->num_rows <= row)
++ return 0;
++
+ row_start = mdb_get_int16(mdb, (fmt->row_count_offset + 2) + (row*2));
+ row_end = mdb_find_end_of_row(mdb, row);
+
+--- src/libmdb/file.c 2003-01-12 17:59:43.000000000 -0500
++++ src/libmdb/file.c 2003-01-23 14:43:04.000000000 -0500
+@@ -20,7 +20,7 @@
+ #include "mdbtools.h"
+
+ MdbFormatConstants MdbJet4Constants = {
+- 4096, 0x0c, 12, 45, 47, 51, 55, 56, 63, 12, 15, 23, 5, 25
++ 4096, 0x0c, 16, 45, 47, 51, 55, 56, 63, 12, 15, 23, 5, 25
+ };
+ MdbFormatConstants MdbJet3Constants = {
+ 2048, 0x08, 12, 25, 27, 31, 35, 36, 43, 8, 13, 16, 1, 18