Bug in Dialog when M is smaller then the Sum of private key