As someone else said, the difference between expert and lawyer is in the beholder.
That difference is usually in mannerism and confontationalism. The expert presents and explains the rule to inform the GM.
The lawyer argues and wheedles. Its annoying and disruptive behavior.
No offense to Danny, who is a lawyer, but it got termed "Rules Lawyer" as a negative play on the way lawyers are percieved by society.
This doesn't speak to whether the rules lawyer is actually RIGHT about the rules. Its simply that he's going to argue for his version of them vociferously. He's a right-fighter, in that he has to fight to prove he is right.
Add to all of this, is playing with a DM who doesn't know that the smurf he's doing. He gets the rules wrong, etc. And he thinks he's right. His judgement is unassailable.
If you have a DMoron, that's a problem.
If you have a Rules Lawyer, that's a problem.
In a good table, you've got a rules expert on whom to rely on correct interpretations of rules when questions come up, and you've got a DM who will ask and listen when somebody knows the rule.