It's quite clear that a whole class of humor is offensive but is still funny. And no, there shouldn't be any lines drawn - there are jokes that is both funny and also obscenely offensive to various races, religions, nations or ethical viewpoints; but there is no such thing as too offensive, even if they are about, for example, the funny habits of babyraping [$ethnic] priests of [$religion].
There definitely are (a lot of) jokes that are inappropriate to a particular situation and impolite to a particular audience, where it would be hurtful and/or incite conflict - but all of them are suitable in other situations and audiences.
There definitely are (a lot of) jokes that are inappropriate to a particular situation and impolite to a particular audience, where it would be hurtful and/or incite conflict - but all of them are suitable in other situations and audiences.