Inherit the major mode from the originating buffer

We already know a suitable major mode from the originating buffer, so
let's simply inherit it instead of choosing it automatically again.

This makes sure that the mode is properly set up, if the user explicitly
chose a different mode than the one automatically chosen.