Danville man sentenced to prison for weapon possession