Dawn of Television Injustice

I was watching a rerun of Law & Order a few days ago, and the episode ended with the upper-crust murderess getting off on a technicality, smirking at a stunned McCoy and sauntering out of the courtroom. A though came to me suddenly - Perry Mason would have never let this happen.

In the classic TV crime or court dramas, the bad guys never walked, nor did the innocent ever serve time. I can’t think of a single program aired before 1980 or so that left its viewers, even occasionally, reeling from injustice when the credits rolled. At the very worse, the killer walked out of the courtroom to be gunned down by his victim, a la Bruce Willis in Miami Vice - justice poetic, if not strictly legal. My question is, when was the shift? When was the American public finally ready to deal with the fact that the world, and more specifically, their own legal system, just wasn’t perfect? Were there any early exceptions?

I’m spouting off the top of my head here, so no cites, and if someone wants to give additional detasil, please do.

I think this a holdover from the old Hayes Code for motion pictures. Sometime in the 1930’s, I think, as people were concerned about movies getting “out of control,” the Hayes Code was accepted by all the movie studios (not sure if it was legally binding or not). It cut down on sex (Mae West’s movies were before the code took effect, and could not be made after) and one of the stipulations was that the bad guys could not get away.

As our culture progressed into the 60’s, independent filmmakers started to stray, and as it became obvious the mainstream accepted these movies, I think by the late 60’s (wasn’t Midnight Cowboy 1969?) and early 70’s movies could basically do whatever they wanted. Thus the adoption then of the ratings system.

The same thing carried over to TV, if not officially, then as a result of the networks making sure never to push the edge too far. So I think the same barriers being broken on TV shows came a decade later.

Had I to pick a watershed moment, it would be the Godfather movies of the early seventies, in which the main characters are sympathetic and interesting… and murderous, with no inevitable legal consquences. There had been earlier sympathetic anti-heroes, like Bonnie and Clyde and Butch Cassidy and the Sundance Kid, but they still died at the end in a hail of righteous gunfire.

The first “realistic” crime television drama (i.e. bad guys not always punished, innocents sometimes convicted) was arguably Hill Street Blues, which started in 1981. It showed many of the grittier, messier elements of big-city law enforcement. Offhand, I can’t think of anything earlier that meets the OP’s criteria.