fix #941 fork is interrupted by discard alert