Hi,
To simplify...
If an I/O pin is set as an output, you should never short it to Vss (ground/0V) or Vdd (the positive voltage), or anything else for that matter, since the controller powers the pin. However, if the output is low (0V), shorting it to ground will do no harm, as there is no potential difference, same goes for a high output shorted to Vdd.
An I/O pin set as an input pin, on the other hand, can be shorted to any voltage potential between Vss and Vdd, for as long as you like, since it is an input and supposed to get... Well, an input. (It has nothing to do with potential dividers).