home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!destroyer!sol.ctr.columbia.edu!The-Star.honeywell.com!umn.edu!news
- From: teb@dendron.forestry.umn.edu (Thomas E. Burk)
- Subject: BORLAND C++ w/ObjWin -- linker error with global variables
- Message-ID: <1992Jul24.223801.8065@news2.cis.umn.edu>
- Keywords: BORLAND LINKER
- Sender: news@news2.cis.umn.edu (Usenet News Administration)
- Nntp-Posting-Host: dendron.forestry.umn.edu
- Reply-To: teb@dendron.forestry.umn.edu (Thomas E. Burk)
- Organization: University of Minnesota
- Date: Fri, 24 Jul 1992 22:38:01 GMT
- Lines: 25
-
- I declared several variables and functions globally with Borland C++ with
- ObjectWindows. Using the small memory model option, I receieved a message
- from the linker saying segment_TEXT exceeded 64K. My Windows C++ application
- did compile successfully but failed to link because of a segmentation fault.
-
- To resolve that, I attempted to declare a global pointer to a class that
- encapsulated all the 'global' variables and functions. The application
- linked successfully under the large memory model but failed upon execution with
- a "general protection fault" error before the global pointer was constructed.
-
- How can I fix this problem? Perhaps by declaring the global pointer as a far
- pointer? How about increasing the stack/heap size and coercing the variables
- and pointers to be placed in the heap?
-
-
- Man V. Nguyen
- University of Minnesota
- Internet: mnguyen@mercury.forestry.umn.edu
-
- --
- Thomas E. Burk
- University of Minnesota
- Internet: teb@dendron.forestry.umn.edu
- BITNet: teburk@umnacvx.bitnet
- USFS DG: t.burk:x400
-