Fix pgwgcompmax