The Young Land
(1959)

The movie is set in California in 1848, while it is a US territory before statehood.  A drunken cowboy, Hatfield Carnes (Dennis Hopper) guns down a mexican man outside the saloon for getting "mouthy" with him.  

Carnes is surprised when Sheriff Ellison (Patrick Wayne) arrests him since "it was just a mexican".  Ellison has trouble asserting authority, because there is no real government yet, and Ellison just appointed himself sheriff.  A federal judge and marshall come for the trial.  They have trouble seating a jury, as Carnes's gang of roughnecks make it clear that the jury will have to answer to them.  A large number of mexican vaqueros also arrive to make sure there is justice for their buddy.

Carnes treats the whole trial as a big joke and is openly disrespectful with the judge and marshall.  The jury finds Carnes guilty.  The judge had acted very tough all along.  However, now he appears frightened of the crowd.  The judge sentences Carnes to 25 years in jail, but immediately suspends the sentence, allowing Carnes to go free.  Carnes grabs a gun from the deputy, and says he will make Ellison pay for arresting him.  Carnes backs out the courtroom door, and demands that Ellison come out and face him.  He threatens to shoot anyone else who comes out the door.  Ellison comes out, and shoots Carnes.

The movie ends with the judge delivering a speech about how the mexicans have now seen that American justice is fair and applies equally to all.

This is ironic, considering how the judge just cravenly set a murder free, but it appears the filmmakers intended no irony.  

Thanks Joseph C!