(svn r5911) -Fix [FS#215]: Discard upper bits of TrackdirBitsToTrackBits result.

This commit is contained in:
matthijs 2006-08-15 11:06:32 +00:00
parent b13a60db42
commit 49b7b1e0eb

2
rail.h
View File

@ -296,7 +296,7 @@ static inline TrackdirBits TrackToTrackdirBits(Track track)
*/
static inline TrackBits TrackdirBitsToTrackBits(TrackdirBits bits)
{
return (TrackBits)(bits | (bits >> 8));
return (TrackBits)((bits | (bits >> 8)) & TRACK_BIT_MASK);
}
/**