That's probably a good idea, especially for the cases where you repurpose a charging cable, so you'd have a quite long wire connected to the control pilot (CP) input, running in parallel with AC wires that may have some switching noise on them. The long unconnected wire acts a bit like an antenna. It is likely to cause noise and/or 50 Hz AC inductively coupled into the control pilot input, which could conceivably cause glitches or maybe even damage the control pilot input to your on-board charger. The OBC could cost of the order of £3000 to replace. The risk is small, but the effort to short the two pins is also small, so you may as well do that as part of "best practice". Though it might be easier and just as effective to simply cut the CP wire near the vehicle end.
Edit: Or do both: cut the CP wire 70 mm from the pin, and use the short end to connect to earth.