TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: KURT KUZBA
from: ANTHONY TIBBS
date: 1997-04-23 17:42:00
subject: Random access files

On Apr 19 11:09, 1997, Kurt Kuzba of 1:154/750 wrote:
KK>       char* FromName[36];
KK>       char* ToName[36];
KK>       char* Subject[72];
"char *FromName [36];" ?  This won't/shouldn't even compile correctly.  You 
*should* be using either of the following two methods:
char *FromName;
char *Toname;
char *Subject;
. 
.
.
FromName = malloc (36);
Toname = malloc (36);
Subject = malloc (72);
(Of course, do error checking)
OR
char FromName [36];
char Toname [36];
char Subject [72];
The second method would be the easiest.  However, the the method you 
specified is saying this:  I want a pointer to a pointer to a 36 byte char.  
(I know it is possible to have a pointer to a pointer, but not in this case.)
Anthony
--- TriED 0.10 alpha 1
---------------
* Origin: World of Power BBS (1:163/545.15)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.