Some minor fixes

The two first patches fix a non-logical thing : casting an unsigned as a signed to compare it with unsigned.
The third one is more a warning fix : as the 'printer' parameter is unused. Then I chose to reset it.
The last one is to remove an unused trailing white space (you can ignore this one).