control the range for setting age_public_flag(fixes #3453)

control the range for setting age_public_flag(fixes #3453)