Re: [Monetdb-developers] [Monetdb-pf-checkins] pathfinder/compiler/algebra/opt opt_algebra_cse.c, , 1.33, 1.34
Hi Teggy, is this a bug fix that should also (have) be(en) applied in the XQuery_0-24 release branch? Stefan On Mon, Jul 07, 2008 at 07:19:00AM +0000, Torsten Grust wrote:
Update of /cvsroot/monetdb/pathfinder/compiler/algebra/opt In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv6385
Modified Files: opt_algebra_cse.c Log Message: -- Fixed attribute list allocation bug in structural algebra CSE.
U opt_algebra_cse.c Index: opt_algebra_cse.c =================================================================== RCS file: /cvsroot/monetdb/pathfinder/compiler/algebra/opt/opt_algebra_cse.c,v retrieving revision 1.33 retrieving revision 1.34 diff -u -d -r1.33 -r1.34 --- opt_algebra_cse.c 18 Jun 2008 11:24:23 -0000 1.33 +++ opt_algebra_cse.c 7 Jul 2008 07:18:57 -0000 1.34 @@ -1330,21 +1330,23 @@ ACTATT(R(n), n->sem.ser_seq.item));
case la_serialize_rel: - { - PFalg_attlist_t items = (PFalg_attlist_t) { - .count = n->sem.ser_rel.items.count, - .atts = PFmalloc (sizeof(PFalg_att_t)) - }; - - for (unsigned int i = 0; i < items.count; i++) { - items.atts[i] = ACTATT (L(n), n->sem.ser_rel.items.atts[i]); - } - + { + PFalg_attlist_t items = + (PFalg_attlist_t) { + .count = n->sem.ser_rel.items.count, + .atts = PFmalloc (n->sem.ser_rel.items.count * + sizeof(PFalg_att_t)) + }; + + for (unsigned int i = 0; i < items.count; i++) { + items.atts[i] = ACTATT (L(n), n->sem.ser_rel.items.atts[i]); + } + return PFla_serialize_rel (CSE(L(n)), ACTATT (L(n), n->sem.ser_rel.iter), ACTATT (L(n), n->sem.ser_rel.pos), items); - } + } case la_lit_tbl: return PFla_lit_tbl_ (create_attlist (n->schema), n->sem.lit_tbl.count,
------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08 _______________________________________________ Monetdb-pf-checkins mailing list Monetdb-pf-checkins@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
participants (1)
-
Stefan Manegold