Profile-free earthing and short-circuiting of railway overhead lines