IBM/PC C, 2 questions.

Steve L Vissage II svissag at hubcap.clemson.edu
Thu Nov 1 05:54:23 AEST 1990


I was working on a program today, and I got 2 errors I couldn't fathom.
 
  1) #define say(whatever)  fputs(whatever,stdout)
 
     In previous versions, this never caused a problem, but when I made
     today's additions and compiles, I kept getting the warning 
      "Suspicious pointer conversion"
     at every occurrence of the say() macro.  However, the programs runs
     and works perfectly.  
 
     Can anyone explain that?
 
  2) This is probably a Turbo C question, rather than strictly C.
     
     I made several changes to this program, recompiled, and used the 
     OS shell to test it.  After several flips to & from the shell, I
     suddenly got an "Out of Memory"  error when I tried to compile.
     Let me stress that I had done nothing different this time than any
     previous.  I saved the current version, rebooted, and it compiled fine.

     Was I doing something wrong?  Not telling TC to clear something?
     Or was the program eating memory?  But isn't it supposed to clear
     the memory it uses when the program ends?  (There are no malloc()'s
     or free()'s, so it's nothing I KNOW I'm supposed to free.)
 

Thanks for listening,
Steve L Vissage II 



More information about the Comp.lang.c mailing list