Ticket #8985: no-fpermissive.diff

File no-fpermissive.diff, 4.2 KB (added by dhewg, 15 years ago)
  • engines/agi/lzw.cpp

     
    144144        setBits(START_BITS);    /* Starts at 9-bits */
    145145        lzwnext = 257;          /* Next available code to define */
    146146
    147         end = (unsigned char *)((long)out + (long)len);
     147        end = (unsigned char *)((size_t)out + (long)len);
    148148
    149149        lzwold = inputCode(&in);        /* Read in the first code */
    150150        c = lzwold;
  • engines/scumm/gfx.cpp

     
    603603
    604604                // The values x, width, etc. are all multiples of 8 at this point,
    605605                // so loop unrolloing might be a good idea...
    606                 assert(0 == ((long)text & 3));
     606                assert(0 == ((size_t)text & 3));
    607607                assert(0 == (width & 3));
    608608
    609609                // Compose the text over the game graphics
  • engines/agos/subroutine.cpp

     
    220220}
    221221
    222222void AGOSEngine::alignTableMem() {
    223         if ((unsigned long)_tablesHeapPtr & 3) {
     223        if ((size_t)_tablesHeapPtr & 3) {
    224224                _tablesHeapPtr += 2;
    225225                _tablesHeapCurPos += 2;
    226226        }
  • engines/sky/compact.cpp

     
    3434
    3535#define SKY_CPT_SIZE    419427
    3636
    37 #define OFFS(type,item) (((long)(&((type*)0)->item)))
     37#define OFFS(type,item) (((size_t)(&((type*)0)->item)))
    3838#define MK32(type,item) OFFS(type, item),0,0,0
    3939#define MK16(type,item) OFFS(type, item),0
    4040#define MK32_A5(type, item) MK32(type, item[0]), MK32(type, item[1]), \
  • graphics/scaler.cpp

     
    194194                                                        int width, int height) {
    195195        uint8 *r;
    196196
    197         assert(((long)dstPtr & 3) == 0);
     197        assert(((size_t)dstPtr & 3) == 0);
    198198        assert(sizeof(OverlayColor) == 2);
    199199        while (height--) {
    200200                r = dstPtr;
     
    220220        const uint32 dstPitch2 = dstPitch * 2;
    221221        const uint32 dstPitch3 = dstPitch * 3;
    222222
    223         assert(((long)dstPtr & 1) == 0);
     223        assert(((size_t)dstPtr & 1) == 0);
    224224        while (height--) {
    225225                r = dstPtr;
    226226                for (int i = 0; i < width; ++i, r += 6) {
     
    255255        const uint32 dstPitch3 = dstPitch * 3;
    256256        const uint32 srcPitch2 = srcPitch * 2;
    257257
    258         assert(((long)dstPtr & 1) == 0);
     258        assert(((size_t)dstPtr & 1) == 0);
    259259        while (height > 0) {
    260260                r = dstPtr;
    261261                for (int i = 0; i < width; i += 2, r += 6) {
  • backends/midi/windows.cpp

     
    6262                return MERR_ALREADY_OPEN;
    6363
    6464        _streamEvent = CreateEvent(NULL, true, true, NULL);
    65         MMRESULT res = midiOutOpen((HMIDIOUT *)&_mo, MIDI_MAPPER, (unsigned long)_streamEvent, 0, CALLBACK_EVENT);
     65        MMRESULT res = midiOutOpen((HMIDIOUT *)&_mo, MIDI_MAPPER, (size_t)_streamEvent, 0, CALLBACK_EVENT);
    6666        if (res != MMSYSERR_NOERROR) {
    6767                check_error(res);
    6868                CloseHandle(_streamEvent);
  • backends/platform/sdl/graphics.cpp

     
    793793        assert(h > 0 && y + h <= _videoMode.screenHeight);
    794794        assert(w > 0 && x + w <= _videoMode.screenWidth);
    795795
    796         if (((long)src & 3) == 0 && pitch == _videoMode.screenWidth && x == 0 && y == 0 &&
     796        if (((size_t)src & 3) == 0 && pitch == _videoMode.screenWidth && x == 0 && y == 0 &&
    797797                        w == _videoMode.screenWidth && h == _videoMode.screenHeight && _modeFlags & DF_WANT_RECT_OPTIM) {
    798798                /* Special, optimized case for full screen updates.
    799799                 * It tries to determine what areas were actually changed,
     
    997997
    998998void OSystem_SDL::addDirtyRgnAuto(const byte *buf) {
    999999        assert(buf);
    1000         assert(((long)buf & 3) == 0);
     1000        assert(((size_t)buf & 3) == 0);
    10011001
    10021002        /* generate a table of the checksums */
    10031003        makeChecksums(buf);