Michel Oosterbeek oosterbeek.mah at stu.hsbrabant.nl
Tue Feb 19 04:16:00 CST 2002

Hi all,

So far I have gotten no response to my question. I really hope someone is
able to provide me with an answer as my graduation depends on it :o)

I'm using Jabber 1.4.1 on Red Hat 7.2 and I've tried to get XDB-ODBC
running, but for some reason nothing much seemed to happen.

Because after numerous attempts to get it right there were still no results,
I decided to give it a try myself, and started writing my own version. Again
I encountered a problem. I may have misunderstood the way xdb_file works,
but as far as I could comprehend the code, there are only two 'locations'
where the actual file (user.xml) is accessed:

In xdb_file.c:

- in the function  "xdb_file_load"  I found
  "xmlnode_file(fname)"   (I suppose this is where the read is done?)
- in the function "xdb_file_phandler"  I found
  "xmlnode2file(full,file)"   (so here the file is saved?)

And so all I did was simply replacing these two lines with my own 2
functions.  These functions simply "cut" the full pathname in to pieces and
determine the server_jid, username, etc...  Next, I use this info to store
the file into my database using ODBC. So I didn't change any code in Jabber
except for those two lines in xdb_file.c.

Now for my problem. My code seems to work fine. Running it seperately from
Jabber gives good results with retrievals, storing, etc. When I run Jabber
with a debugger, I can see the database is accessed, and the retrieval is
done properly. The user passes authorisation, so that "should" mean my code
gave back the user.xml all right.   But still, something must be wrong as
after authorisation I get a segmentation fault and an error from dnssrv.c.

Can anyone tell me what it is I am overlooking? Probably something more is
happening then just the read/write action I mentioned above...

Thanks in advance,


More information about the JDev mailing list