Changeset de91266 in buchla-68k for ram


Ignore:
Timestamp:
11/12/2017 08:27:47 PM (6 years ago)
Author:
Thomas Lopatic <thomas@…>
Branches:
master
Children:
210d896
Parents:
f798356
Message:

Fixed delpnts.c.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • ram/delpnts.c

    rf798356 rde91266  
    9494
    9595                *(fpu + (fnoff[i] << 4) + FPU_TCTL) =
    96                    (fp->idftmd = (fp->idftmd & ~3) | 1);
     96                   (uint16_t)(fp->idftmd = (fp->idftmd & ~3) | 1);
    9797        }
    9898
     
    106106                pp2 = &vp->idhpnt[pt2];
    107107
    108                 for (i = nmv * PT_SIZE; i > 0; i--)
     108                for (i = nmv * (int16_t)PT_SIZE; i > 0; i--)
    109109                        *pp1++ = *pp2++;
    110110
    111111                /* adjust total points remaining */
    112112
    113                 vp->idhplft += np;
     113                vp->idhplft = (int8_t)(vp->idhplft + np);
    114114
    115115                /* adjust number of points in this function */
    116116
    117                 vp->idhfnc[curfunc].idfpif -= np;
     117                vp->idhfnc[curfunc].idfpif =
     118                        (int8_t)(vp->idhfnc[curfunc].idfpif - np);
    118119
    119120                /* adjust starting points in other functions */
    120121
    121122                for (cf = curfunc + 1; cf < NFINST; cf++)
    122                         vp->idhfnc[cf].idfpt1 -= np;
     123                        vp->idhfnc[cf].idfpt1 =
     124                                (int8_t)(vp->idhfnc[cf].idfpt1 - np);
    123125
    124126                setipl(oldi);           /* +++++ restore interrupts +++++ */
     
    154156                        pp2 = &vp->idhpnt[pt2];
    155157
    156                         for (i = nmv * PT_SIZE; i > 0; i--)
     158                        for (i = nmv * (int16_t)PT_SIZE; i > 0; i--)
    157159                                *pp1++ = *pp2++;
    158160
    159161                        /* adjust total points remaining */
    160162
    161                         vp->idhplft += (np - 1);
     163                        vp->idhplft = (int8_t)(vp->idhplft + (np - 1));
    162164
    163165                        /* adjust number of points in this function */
    164166
    165                         vp->idhfnc[curfunc].idfpif -= (np - 1);
     167                        vp->idhfnc[curfunc].idfpif =
     168                                (int8_t)(vp->idhfnc[curfunc].idfpif - (np - 1));
    166169
    167170                        /* adjust starting points in other functions */
    168171
    169172                        for (cf = curfunc + 1; cf < NFINST; cf++)
    170                                 vp->idhfnc[cf].idfpt1 -= (np - 1);
     173                                vp->idhfnc[cf].idfpt1 =
     174                                        (int8_t)(vp->idhfnc[cf].idfpt1 - (np - 1));
    171175                }
    172176
Note: See TracChangeset for help on using the changeset viewer.