| ftp.delorie.com/archives/browse.cgi | search |
| From: | "Vermin" <ratspl AT hotmail DOT com> |
| Newsgroups: | comp.os.msdos.djgpp |
| References: | <k1BP6.1409$vu4 DOT 130732 AT news3 DOT oke DOT nextra DOT no> <Xns90AE75691951Bmanniheumanngmxde AT 130 DOT 133 DOT 1 DOT 4> <c9dQ6.2081$vu4 DOT 202315 AT news3 DOT oke DOT nextra DOT no> <Xns90AF7A1A5C9F0manniheumanngmxde AT 130 DOT 133 DOT 1 DOT 4> |
| Subject: | Re: Help... classes and optimization problem |
| Lines: | 26 |
| X-Priority: | 3 |
| X-MSMail-Priority: | Normal |
| X-Newsreader: | Microsoft Outlook Express 5.00.2919.6600 |
| X-MimeOLE: | Produced By Microsoft MimeOLE V5.00.2919.6600 |
| Message-ID: | <JguQ6.2118$lM3.46301@news1.oke.nextra.no> |
| NNTP-Posting-Host: | 130.67.72.139 |
| X-Complaints-To: | news-abuse AT nextra DOT no |
| NNTP-Posting-Date: | Mon, 28 May 2001 17:37:13 MET DST |
| Organization: | Nextra Public Access |
| X-Trace: | readme.online.no 991064233 130.67.72.139 |
| Date: | Mon, 28 May 2001 17:39:48 +0200 |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
This is the constructor and the function it calls:
palette::palette(char *file){
LoadPal(file);
}
bool palette::LoadPal(char *file){
uchar sLength = strlen(file);
char ext[4];
strcpy(ext, (file + sLength - 4));
strupr(ext);
if (strcmp(ext, ".PAL") == 0){
return LoadPALpal(file);
}else if (strcmp(ext, ".PCX") == 0){
return LoadPCXpal(file);
}else if (strcmp(ext, ".BMP") == 0){
return LoadBMPpal(file);
}else{
return false;
}
}
I'm sure that the problem is located in the constructor, since when I use
the default constructor, it all works well...
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |