Changeset 4bf79af in rtems


Ignore:
Timestamp:
Mar 16, 2016, 9:28:03 AM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
b0443736
Parents:
f2f207ce
git-author:
Sebastian Huber <sebastian.huber@…> (03/16/16 09:28:03)
git-committer:
Sebastian Huber <sebastian.huber@…> (03/16/16 12:35:26)
Message:

timecounter: Avoid invalid memcpy()

In uni-processor configurations we have only one timehand. Do not issue
a memcpy() with equal source and destination.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/score/src/kern_tc.c

    rf2f207ce r4bf79af  
    14121412         */
    14131413        tho = timehands;
     1414#if defined(RTEMS_SMP)
    14141415        th = tho->th_next;
     1416#else
     1417        th = tho;
     1418#endif
    14151419        ogen = th->th_generation;
    14161420        tc_setgen(th, 0);
     1421#if defined(RTEMS_SMP)
    14171422        bcopy(tho, th, offsetof(struct timehands, th_generation));
     1423#endif
    14181424
    14191425        /*
     
    15531559#endif
    15541560
     1561#if defined(RTEMS_SMP)
    15551562        timehands = th;
     1563#endif
    15561564#ifndef __rtems__
    15571565        timekeep_push_vdso();
Note: See TracChangeset for help on using the changeset viewer.