An infinite step size doesn't happen somehow - you have assigned it explicitly. So this is your code:

Qt Code:
  1. if ( !qIsFinite ( stepSize ) )
  2. stepSize = -1;
  3.  
  4. plot->setAxisScale( ..., stepSize ):
To copy to clipboard, switch view to plain text mode 
It is not the job of Qwt to deal with any type of nonsense the application code does. When passing a double it has to be valid otherwise the result is undefined.

Uwe