allow xdo_free(NULL) without segfaults
constify display argument in xdo_new() since it will not be modified.