Any person who unlawfully and with gross negligence places or causes to be placed any obstruction upon or near the track of any railroad that proximately results in either the damaging or derailing of any passenger, freight, or other train, or injures a rail passenger or employee, shall be punished by imprisonment pursuant to subdivision (h) of Section 1170 for two, three, or four years, or by imprisonment in a county jail for not more than one year, or by a fine not to exceed two thousand five hundred dollars ($2,500), or by both that imprisonment and fine.
Ca. Pen. Code § 218.1