Forum OpenACS Development: danger: stack grown too large?

Collapse
Posted by Andrew Turner on

I've been getting "stack grown too large" errors on a couple of different stock ACS pages. Some I've been able to resolve by doing stupid things.

For instance: /bboard/message-new-2, the URI of the confirm post page, produced this error until I removed code that deals with attachments from simple-message.adp (which is included by message-preview.adp which is used by message-new-2). Here's what I removed (as I say, removing this fixed the problem):

<if @display_attach_p@ nil or @display_attach_p@ ne "f">
 <if @id@ not nil and @attachments_p@ not nil and @attachments_p@ ne "f">
  <if @attachments:rowcount@ gt 0>
  <tr><td><i>Attachment:</i>
   <multiple name="attachments">
    <a href="attachment?file_id=@attachments.file_id@">@attachments.name@</a> - @attachments.title@
    <if @write_p@ not nil and @write_p@ ne "f">                                                          
     [<a href="attachment-delete?file_id=@attachments.file_id@&message_id=@id@">delete</a>]
    </if><br />                                                                                
   </multiple></td></tr>
  </if>
 </if>
</if>

I've also found this error when I try to add a group. I haven't been able to "fix" that problem though (as I don't really understand the cause of the problem).

Any help would be much appreciated.

Collapse
Posted by Don Baccus on
You need to set stacksize to a larger value. This works for me:
ns_section "ns/threads"
ns_param stacksize [expr 128*1024]
Collapse
Posted by Jonathan Marsden on
OK, so it wasn't just me who got caught by this!

I've just written a patch to acs-bootstrap-installer/installer/index.tcl to check for this issue at install time.  I'll email it to Don shortly.

Collapse
Posted by Don Baccus on
Thanks, Jonathan, or enter it into the SDM.  I hadn't gotten around to it myself, yet, but it was still on my list.  I'll apply your patch as soon as I get it.