
Tree House of Horror III: The Simpson's Halloween Special III - S4-E5
Continuity mistake: When Bart gets the Krusty doll, he pulls the pull string from the back of the doll. When the doll has finished talking, the pull ring has disappeared. (00:04:05)

Tree House of Horror III: The Simpson's Halloween Special III - S4-E5
Continuity mistake: When Homer finds out the doll is trying to kill him, the popcorn moves from the sofa onto his lap. (00:04:40)

Tree House of Horror III: The Simpson's Halloween Special III - S4-E5
Continuity mistake: In King Homer, When Burns is telling the reporters what the ape will be doing, the crowd in the background are devoid of any facial features. (00:11:40)

Tree House of Horror III: The Simpson's Halloween Special III - S4-E5
Continuity mistake: When Homer is escorting his family out of the house to escape the Zombies, he leaves the door wide open, but in the very next shot it is shut. (00:18:50)
Answer: I'm not sure if this is the one you're thinking of, but an episode of "Ray Bradbury Theatre," called "A Sound of Thunder," dealt with a similar matter: a group of hunters travel back in time to hunt dinosaurs, only to find things have changed when they get back because someone stepped on a butterfly.
Xofer