Yep its an error all right. The way it is will cause an infinite loop. The "inc %p" line should be "inc %w"