Leroy and Jim both lose fights in their respective songs, but in a fight against each other where the weapons are lyrical quality and characterization, Leroy comes out ahead.
Chief among "You Don't Mess Around with Jim's" weaknesses is its jumbled chorus:

You don't spit into the wind
You don't pull the mask off that old Lone Ranger
And you don't mess around with Jim
Faulty comparisons abound. The composition is meant to suggest a list of things that are as dangerous as messing around with Jim, a big tough criminal who will beat you up. Croce gives us for comparison two avengers on the side of justice and a frankly unpoetic, comically understated situation. The net result is discord rather than the desired effect: it's unclear what exactly happens when you mess around with Jim. Spitting into the wind is a metaphor for a plan that backfires, which does not accurately describe the Jim situation. If you're messing around with Jim, you're trying to provoke him. The end result is that you lose, but it's not exactly a backfire.
Nor is it like the other two situations described. It is highly unlikely that you, an average, law-abiding citizen, will be reduced to a bloody pulp by surprising Superman with a little cape-tug. He's the shiny too-good defender of all that is pleasant, not a loose cannon in a bad cop movie. The same is true of the Lone Ranger: though he might be upset at you for revealing his secret identity, he's probably not going to gun you down unless you're already a villain.
Compare this chorus to the one in "Bad, Bad Leroy Brown."
And he's bad, bad Leroy Brown
The baddest man in the whole damn town
Badder than old King Kong
Meaner than a junkyard dog
Simpler and more informative. The message is clear: Leroy Brown is bad and mean. Croce's comparisons are more spot-on here. King Kong is bad (in the sense of destructive quality), and a junkyard dog is mean and more importantly, dangerous. These images say a little more than their words alone seem to, and what's more, they characterize the man in question.
Characterization is another thing that Leroy has in buckets more than Jim. The first half of the song consists mostly of descriptions of the man.
Now Leroy, he a gambler
And he like his fancy clothes
And he like to wave his diamond rings under everybody's nose
He got a custom Continental
He got an El Dorado too
He got a .32 gun in his pocket for fun
He got a razor in his shoe
The song goes on to characterize him even more after this crystal-clear portrait. By the end of the song, we know that Leroy is a flamboyant gambler and a cocky showoff. We understand the nature of his hubris in his pursuit of Doris, the wife of a jealous man. He is a full-fledged character whose fate we are invested in.
The following is the sum total of the characterization of Big Jim Walker.
Uptown got its hustlers
The Bowery got its bums
42nd street got Big Jim Walker
He's a pool-shootin' son of a gun
He's big and dumb as a man can come
But he's stronger than a country hoss
And when the bad folks all get together at night
They all call Big Jim "Boss"
Slightly more words to describe significantly less. What we know of Jim after this and for the rest of the song is that he is a big dumb fixture of 42nd street who likes playing pool. We are not given examples of any of these qualities to make us believe in them. To bring up a tired creative writing phrase, we are told, not shown.
At the end of both songs, these men (or this man and this bare outline of a man) meet the same fate. Or do they? Leroy Brown thinks he's invincible, thinks he can mess around with the wife of a jealous man, and after the fight he looks like "a jigsaw puzzle with a couple of pieces gone." Big Jim is accused of stealing and murdered in a comically gruesome manner: he is cut everywhere but the soles of his feet and he is shot several more than one hundred times.
The mesasges at the end of both songs also vary. Leroy Brown suffers for his pride. His punishment fits his crime. The song ends with the chorus repeated exactly the same as before, except now it is tinged with bitter irony.
At the end of the other song, Big Jim, a big dumb criminal who can't even be called a stereotype because he's barely described at all, is murdered by another street tough who takes his place. At the end of the song the chorus is repeated, only now it's "you don't mess around with Slim."
"Bad, Bad Leroy Brown" is a lesson in humility. "You Don't Mess Around with Jim" is a dark tale of cyclical violence whose seriousness is awkwardly undermined by cartoonish imagery and confusing, poorly-chosen metaphors.
The two songs do sound very similar. But Jim is a first draft of Leroy, a story without a moral told from the confused, ignorant perspective of the crowd. Leroy is a character study with a complete arc. The only other difference is that "You Don't Mess Around with Jim" makes a better album title, which is maybe why Jim Croce never tried to bury it.