I am no electronics expert but by doing that you will get a small voltage, likely due to the internal circuitry of the drive or possibly the wire itself picking up noise. It only takes a few mV to move the motor.
Why are you doing that anyway?
Normally in these drives you can offset the voltage to overcome this creep, in modern drives its done in software, in older drives it was done via a pot.
I fitted a servo to the spindle of my manual lathe (gearbox was noisy) and I use a =-10v via a pot to control speed but use auxiliary position input to stop and hold the motor stationary. Without using the position mode the motor would creep like you are seeing, I could offset that in the software but it would obviously affect the reverse direction rotation as the voltage in reverse would need to be higher than the offset before it would turn.
When connected to a CNC control this is likely not an issue as the control itself would see the motor moving so would command an opposite voltage to hold it stationary.
Hood