Subj : AddRoot on the table of pointers To : netscape.public.mozilla.jseng From : Aleksander Wysocki Date : Mon Jan 26 2004 10:36 am hi all! for some reasons i need a little richer AddRoot function. normally when i need to protect an object of gc'ing i do as follows: JS_AddRoot(ctxt, &ptr_to_my_js_object); but if i have many objects - in a table such as: jvalue table[100]; or JSObject * table[100]; i have to AddRoot every object in the table, what seems to be silly, because all of them will stay in the internal hashtable which contains roots. i haven't found any legal (or illegal) function: JS_AddRoot(ctxt, table, table_len) to add whole table as set of roots. does anybody know how to do it? (if possible) or maybe there are some alternative solutions? thanks in advance aw .