www.delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
Date: | Wed, 06 Jun 2007 10:28:43 +0200 |
From: | Robert Riebisch <Robert DOT Riebisch AT arcor DOT de> |
User-Agent: | Thunderbird 1.5.0.12 (Windows/20070509) |
MIME-Version: | 1.0 |
Newsgroups: | comp.os.msdos.djgpp |
Subject: | error: invalid lvalue in increment |
Lines: | 37 |
Message-ID: | <46667036$0$20285$9b4e6d93@newsspool3.arcor-online.net> |
Organization: | Arcor |
NNTP-Posting-Date: | 06 Jun 2007 10:28:38 CEST |
NNTP-Posting-Host: | 5f9a0887.newsspool3.arcor-online.net |
X-Trace: | DXC=G[@kDIb?kJU\PS5Xo=M[RVMcF=Q^Z^V3X4Fo<]lROoRQFl8W>\BH3YRBmT1YO9D0aUB5lc^0gQ=4Q?lK5CCSWJMTZ:eSaake95YLdbnQ;PYYVQbWoWITGh6mX |
X-Complaints-To: | usenet-abuse AT arcor DOT de |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Reply-To: | djgpp AT delorie DOT com |
Hi! Why do I get "error: invalid lvalue in increment" at line "*(((unsigned short *)address)++) = value;" with GCC 4.1.2? I already googled around, but didn't find a `good' solution. Some work around, some recommend GCC 3.4.4, some talk about patching GCC. *** static void rle_tga_read (unsigned char *address, int w, int type, PACKFILE *f) { unsigned char value; int count, g; int c = 0; do { count = pack_getc(f); if (count & 0x80) { count = (count & 0x7F) + 1; c += count; value = pack_getc(f); while (count--) { if (type == 1) *(address++) = value; else *(((unsigned short *)address)++) = value; } } ... *** Taken from http://ase.sourceforge.net/ -- Robert Riebisch Bitte NUR in der Newsgroup antworten! Please reply to the Newsgroup ONLY!
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |