Mysteries of Microsoft Windows and C

Hollis Ross Jr. rossh at umd5.umd.edu
Wed Aug 31 06:07:53 AEST 1988


In article <7050 at umn-cs.cs.umn.edu> kehyoe at umn-cs.cs.umn.edu (Ong Keh Yoe) writes:
>
>Hello,
>
>	I am currently debugging a package written for Microsoft Windows written
>The application calls a second application using a spawnlp.  The spawnlp
                                                    ^^^^^^^
This seems to be a bad idea, from what I know about windows.  
As I understand it, windows grabs up all of the memory from 
the system, and then "distributes" it to the Applications that 
need it as they request it (Global Alloc, Local Alloc, ect..)
Spawnlp would probably erase alot of the resources that windows 
has loaded.  

>kills the parent using an option for spawnlp.  The first application provides
>a graphical menu-driven environment.  The second application on termination
>then spawnlps the first application.  Information to be shared are written
>by each application to two designated files.  Each file created by one
>of the two applications and destroyed by the second.  So fileA is create
>by applicationOne but destroyed by applicationTwo.  And fileB created by
>applicationTwo but destroyed by applicationOne.
>
>	First, I would like to know if anyone has experienced that lack of memory 
>has ever caused programs to terminate inexplicably.  It seems that the
>memory can easily contain both applications.  If the spawnlp kills it's
>parent, should the resources of the parent be automatically freed ?  And if
>not, why not ?  
Memory MAnagment 

>	Third, is it possible to use Codeview to debug these applications

Supposedly CodeView is out for Microsoft Windows.  I haven't seen it yet.

>	Fourth, is the Microsoft window programming environment a stable
>environment ?  Is it reliable ?  What are the best tools and methods

    At times it seems to be not too stable, making you (the programmer) 
a little unstable,  but if you stick with it, you'll pick it up.

>of tackling strange errors ?  E.g. 
>		Using codeview, 
>		Going into Window source (is this possible ?)

    If you use Symdeb, you can step thru your code at the C or
Assembly code level, get a dump of the stack, print out the 
value of Globally decalred variables, and even change their 
values.  All of this debugging is done on a terminal attached 
to com port 1.  

>		Setting some obscure debug flags on ?

     You can set break points at module entry points, or at 
specific C statements in Symdeb. 

>
>				Keh Yoe
>				(the happy hacker)


	Hollis Ross

================================================================================
"Gozer the Gozarian, as a duly appointed represenative   | rossh at umd5.umd.edu
 of the, State, County and City of New York, I do hereby | Bitnet: rossh at umdd
 command you to cease all paranormal activity and return |---------------------
 forthwit to your place of origin, or the nearest 	 | Bill the cat says
 convient parallel dimension" -  Ghostbusters	 	 | "Just say Ack!"
================================================================================



More information about the Comp.lang.c mailing list