Like most things under copyrights (including the scripts in which these lines come from, and the actors under their companies), as long as you reference who the impersonation is of, you are good. I'm only assuming this, just because of stand-up comedians that do the same thing. Before they do the impersonation, they reference where its coming from.
I'm not sure on the actual legality though. I'm sure if the film companies wanted to be anal about it, they could sue them for using such in performances, but since it makes them more money in the long run.....