I think 4th Gen had the best glitches, as they made it seem GF simply had no beta testers by then.
First, the free Pursuit glitch. In JP DP, if the first move your Choicemon used while on the field was Pursuit, and it hit a fleeing pokémon, you would not be locked on it the next turn. Amazingly, this glitch existed in ADV, but no one ever noticed it because lol Pursuit was a special move and we only had Choice Band back then. I guess that was the very first (and only?) time a glitch crossed generations.
Then, the Surf on E4 Glitch. It was in a tile by the outer limits of the map, so, if you used Surf on the first E4 room's door, you'd get in the "black space" of the map and could go pretty much anywhere (except for Hall of Origin, unfortunately). They fixed it in later versions of JP DP (and obviously, US and EUR DP)... but then people discovered the tweaking glitch, which was present since the earliest versions. They only finally solved the problem in Platinum; the glitch is still there, but now you need the event flags from the Oak's Letter and Member Card for Darkrai and Shaymin to appear. Boooooring.
Then we have the Mimic Glitch. It's a bit convoluted, but basically, you could teach any pokémon any move, as long as it learned Mimic. This is because a Transform pokémon would keep the target's moves if it fainted while Transformed, so you could Mimic Transform and use it against an ally Smeargle and... well. The best part is that they fixed it in later versions of JP DP... then HGSS came about and we got a variation of the glitch, but with Rage. Only a handful of pokémon learn Rage compared to Mimic and you could only learn 3 moves but hey, it was still there. And I *think* it didn't exist in JP HGSS, only US/EUR, which made everything much weirder.
And finally, Acid Rain. I fucking swear I don't know how they got themselves in that mess. My best bet is that, as it's known they fixed a small glitch (or simply changed the mechanic) involving U-Turn, Intimidate and Substitute, maybe they also took their time fixing/changing something involving Pursuit and U-Turn and accidentally BUFFER OVERFLOW SCIZOR IS HURT BY ITS TECHICIAN CASTFORM TRANSFORMED!!!! derp.
It's a shame Smogon never adopted Acid Rain. It was beyond retarded and "clearly a glitch", but wasn't gamebreaking and it wasn't fixed by the time US HGSS was released; it lasted longer than Hypnosis's Accuracy increase to 70 and no one considers the latter a glitch, so "developer intent" doesn't mean much lol...