home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / os / os2 / programm / 4325 < prev    next >
Encoding:
Internet Message Format  |  1992-08-19  |  1.3 KB

  1. Xref: sparky comp.os.os2.programmer:4325 comp.lang.c:12529
  2. Newsgroups: comp.os.os2.programmer,comp.lang.c
  3. Path: sparky!uunet!ferkel.ucsb.edu!taco!garfield.catt.ncsu.edu!harris
  4. From: harris@garfield.catt.ncsu.edu (Michael Harris)
  5. Subject: Re: malloc causes a segmentation violation!?
  6. Message-ID: <harris.714243433@garfield.catt.ncsu.edu>
  7. Sender: news@ncsu.edu (USENET News System)
  8. Organization: North Carolina State University
  9. References: <1992Aug18.143135.6259@cc.tut.fi> <3dfy6bq@rpi.edu> <1992Aug19.155648.6210@funet.fi>
  10. Date: Wed, 19 Aug 1992 16:57:13 GMT
  11. Lines: 15
  12.  
  13. mn87504@cs.tut.fi (Naatula Mika) writes:
  14.  
  15. >I thought that OS/2 could detect writes to non-allocated areas and
  16. >give me a segmentation fault right away.  Like it usually does. 
  17.  
  18. What you have to understand is that the area IS allocated as far as the
  19. operating system is concerned.  It is allocated to your process.  Since your
  20. process owns it, the operating system is very happy to let you write there.
  21.  
  22. Memory protection in OS/2 protects one process from another... not a process
  23. from itself.
  24. ______________________________________________________________________________
  25.      Michael Harris - harris@catt.ncsu.edu or harris@carvm3.vnet.ibm.com
  26.  System Administrator, Computer & Technologies Theme Program, NC State Univ.
  27. (My opinions are my own and do not represent those of NCSU or IBM Corporation)
  28.