[Pacemaker] [Question] About the rotation of the pe-file.

Andrew Beekhof andrew at beekhof.net
Mon Jan 16 00:07:04 UTC 2012


On Mon, Jan 16, 2012 at 10:56 AM,  <renayama19661014 at ybb.ne.jp> wrote:
> Hi Lars,
> Hi Andrew,
>
>> If you want it to be between [0, max-1],
>> obviously that should be
>>         while(max > 0 && sequence >= max) {
>>                 sequence -= max;
>>         }
>
> Thanks!!I try it.
>
>> Though I wonder why not simply:
>>     if (max == 0)
>>         return;
>>     if (sequence > max)
>>         sequence = 0;
>
> I wondered, too.
> However, I thought that a cord of Mr. Andrew might have some special specifications.

I was probably trying to get too fancy when dealing with run-time
reduction of max.
Lets go with your way :-)




More information about the Pacemaker mailing list