[Devel] methods patch

Juha Heinanen jh at tutpro.com
Tue Dec 6 12:08:52 CET 2005


Bogdan-Andrei Iancu writes:

 > thanks for the patch - I will committed ASAP- I will have to merge it 
 > with some changes on usrloc I working on right now....it's just a matter 
 > of couple of days.

fine, i'm not in a hurry with it.  if you make changes to usrloc module,
one other thing i noticed is that it contains location table version
twice.  in ul_mod.h:

#define TABLE_VERSION 1001

and in udomain.c:

#define UL_TABLE_VERSION	1001

in my patch i changed the latter to

#define UL_TABLE_VERSION	TABLE_VERSION

but it would be cleaner to rename in ul_mod.h TABLE_VERSION to
UL_TABLE_VERSION and remove the define from udomain.c.

i also noticed that i was not able to write all ones (0xFFFFFFFF) to
methods column of location table.  i first tried to copy how flags was
written:

	vals[6].type = DB_INT;
	vals[6].nul = 0;
	vals[6].val.bitmap_val = _c->flags;

but got 0 to the table with value 0xFFFFFFFF.  i then tried to change
DB_INT to DB_BITMAP, but that didn't help either.  i suspect that there
is a bug in db or mysql code.  finally i just tested if value is
0xFFFFFFFF and if so, wrote NULL.

-- juha



More information about the Devel mailing list