Path: utzoo!utgpu!cunews!bnrgate!brtph3!brchh104!brchs1!bnr.ca!rice.edu!sun-spots-request From: dale@jack.ci.com (Dale Gallaher) Newsgroups: comp.sys.sun Subject: Any problems with malloc on OS 4.1? Keywords: SunOS Message-ID: <1934@brchh104.bnr.ca> Date: 18 Mar 91 17:28:00 GMT Sender: news@brchh104.bnr.ca Organization: Sun-Spots Lines: 24 Approved: Sun-Spots@rice.edu X-Original-Date: 1 Mar 91 14:13:24 GMT X-Sun-Spots-Digest: Volume 10, Issue 54, message 6 X-Note: Submissions: sun-spots@rice.edu, Admin: sun-spots-request@rice.edu For the past few week we have been trying to track down a problem in our application which started when it was used on OS 4.1. It is very sensitive to the users environment. Briefly what happens is that we get a Segmentation Violation in malloc when it is called from putenv. This only happens sometimes and we don't have any problems elsewhere in what is a 9 Meg executable. I have replaced putenv with an older version and I still get the problem; however, when I use an older version of malloc everything works fine. I have heard that malloc was basically rewritten for 4.1 but I don't know this for sure. Since I don't have sources for the new malloc I cannot debug through it and I don't really want to debug through the assembler to figure out what is going on. The application I am having the problem with does use sbrk to allocate some of its own memory. In discussions with some other people it has been mentioned that this might cause problems with the new sun malloc. If anyone has had or knows of any problems with malloc please let me know; otherwise, I will try to go through Sun Support for an answer. Dale Gallaher dale@dandelion.ci.com (508)667-7900 x121