Okay...
1. I'm pretty sure the bad egg thing is kind of like a catch-all for just about any breeding or trading glitch the game comes across. Like, say your link cable got screwed up, or something weird happened with your wireless connection. In any event, maybe the bad egg is kind of like the "catch" clause for any "exceptions" that might occur (Yeah, I'm using coding lingo... I'm a computer scientist; so sue me. I'm just using what I use at work. :/) Whenever the game comes across something it doesn't like during breeding or trading, it just creates a bad egg, and then the user has the option to stop that process (by storing the egg away and never touching it) or just let what was gonna happen happen and lose their game. Anyway, that's what I think.
2. Sue Nintendo? Yeah, I can just see the judge's reaction to your claims:
Guy 1: Dude! This game is totally whacked! Nintendo needs to compensate us for our mental anguish and severe nervous disorders brought on by the tragic loss of our beloved Pokemon!
Guy 2: Yeah! What he said!
Nintendo Representative: We feel that replacements for the cartridges are ample compensation. And as the game is incapable of corrupting the hardware of the Nintendo DS, no replacements are needed for them.
Guy 1: But what about our Pokemon! Our games are fried! You can never replace them!
Guy 2: Yeah! My poor lv. 100 shiny mew... (sniffles)
Judge: I can't believe that you boys are wasting taxpayers' money and the court's time over imaginary creatures represented by game code... I rule in favor of Nintendo corporation. They will replace the afflicted game cartridges, and no further compensation will be made. Case dismissed.
And that's just if Nintendo's feeling generous. You can always restart your game. You haven't REALLY damaged your hardware. It's just the game file that's corrupted.
Now, if you're telling the truth (and I'm going to assume that you are) then there can really be no telling what caused the glitch. But I would think that anything that says "bad egg" would be enough cause for alarm that you wouldn't try to hatch it. I mean, it doesn't take a whole lot of intuition to see that something's not right. I would just trade whatever pokemon you want to keep over to another cartridge and start that one over. Really, there's nothing else you can do at this point, unless you want to play the game with that time bomb in your PC. :/