Bugs item #1649059, was opened at 2007-01-31 18:35
Message generated for change (Comment added) made by boncz
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=1649059&group_id=56967

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: PF/compiler
Group: Pathfinder CVS Head
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Jan Rittinger (tsheyar)
Assigned to: Nobody/Anonymous (nobody)
Summary: XQ: global variables in embedded pf not resetted

Initial Comment:
I now file a bug report based on Jan Flokstra report on problems with memory 
allocation (see: 
http://sourceforge.net/mailarchive/forum.php?thread_id=31561760&forum_id=39803)

His problem (and also mine) is that mem_realloc is called with a NULL pointer. 
(The wrong handling of this NULL pointer should be another bug report.)

This realloc is called by PFarray_at() and PFarray_at() itself is called with a 
PFarray that contains only garbage. The reason for this PFarray to contain only 
garbage is that it is initialized only if the variable that stores the 
reference is set to NULL. This is however not the case when pf is called a 
second time without stopping (e.g. using MapiClient) as the variable itself is 
initialized globally to NULL.

While a fix seems rather easy I opened a bug report instead as this might be 
not the only place where global variables are initialized globally.

Perhaps Peters suggestion to run pf in a separate thread might be a good 
alternative to avoid such problems and to keep Mserver alive even if pf crashes.

----------------------------------------------------------------------

>Comment By: Peter Boncz (boncz)
Date: 2007-05-25 02:36

Message:
Logged In: YES 
user_id=591107
Originator: NO

closing

----------------------------------------------------------------------

Comment By: Jens Teubner (teubner)
Date: 2007-02-01 13:51

Message:
Logged In: YES 
user_id=731390
Originator: NO

Stuff in qnames.c should be clean now.  This should
fix the symptoms that Jan F observed.  Most proably,
this also fixes "Jennie's" bug #1649137.

----------------------------------------------------------------------

Comment By: Jan Rittinger (tsheyar)
Date: 2007-02-01 11:32

Message:
Logged In: YES 
user_id=993208
Originator: YES

Here is a list of affected files -- as far as I can see:
(The ones marked with a star might affect also the stable branch.)

compile.c* (urlcache)
main.c (opt_buf)
oops.c* (PFerrbuf)
qname.c (qnames, qname_hash)
algebra/core2alg.brg (map, map_count, ...)
core/core.c* (core_vars)
core/fs.brg* (any)
debug/abssynprint.c
debug/coreprint.c
debug/milprint.c
include/pathfinder.h* (PFquery)
parser/parser.y* (root, modules, ...)



----------------------------------------------------------------------

Comment By: Jan Rittinger (tsheyar)
Date: 2007-01-31 21:47

Message:
Logged In: YES 
user_id=993208
Originator: YES

Stefan, the bug is triggered by Jens' qname changes to the CVS head. But
as I said before it might be possible that a similar style of programming
might be used throughout pf and thus might trigger bugs (with a less
obvious effect).

----------------------------------------------------------------------

Comment By: Stefan Manegold (stmane)
Date: 2007-01-31 20:12

Message:
Logged In: YES 
user_id=572415
Originator: NO

Any idea, whether this also applies to the latest release branch and hence
should be analyze/fixed there?


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=1649059&group_id=56967

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Monetdb-bugs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-bugs

Reply via email to