VirtualBox

Opened 5 years ago

Last modified 5 years ago

#18337 new defect

"Create a Shortcut on Desktop" overwrites existing shortcut with no warning

Reported by: Socratis Owned by:
Component: other Version: VirtualBox 5.2.0
Keywords: Create Shortcut, overwritten shortcut Cc:
Guest type: all Host type: all

Description

The issue was brought to my attention on IRC by "instantp10neer" and later in a discussion in the forums: https://forums.virtualbox.org/viewtopic.php?f=6&t=91366 by "corhsin" (same user).

If you have a shortcut to the Desktop named exactly as your shortcut-want-to-create, the "Create a Shortcut on Desktop" action overwrites the existing shortcut without asking for confirmation.

Steps to reproduce

  • Create a shortcut on the desktop named "Anything" that points to a text document (for example).
  • Create a new VM in VirtualBox named "Anything".
  • Right-click on the VM, "Create a Shortcut on Desktop".
  • The existing shortcut is overwritten without any confirmation.

Solution

  • Have a confirmation dialog:

    The shortcut/alias "Anything" already exists on the Desktop. Do you want to overwrite it? Y/N


BTW, this occurs since 5.2.0 (didn't go further back, but I don't doubt that it's there for ever), and it happens on Win/Linux hosts. On OSX hosts, the same operation results in a NoOp...

Change History (5)

comment:1 by gombara, 5 years ago

I personally prefer the current behaviour to having yet another confirmation dialog. This one is clearly a "what you get is what you ask" situation.

comment:2 by Socratis, 5 years ago

The current behavior results in data loss/corruption on the host. No matter how small or big. It's an overwrite, there should be a confirmation, no way around it.

No matter your personal (and mine) preferences about confirmation dialogs... ;)

comment:3 by gombara, 5 years ago

If you create a file VirtualBox.log in your vm directory it will be also overwritten. Well not immediately as we recycle these files but soon enough that file content will be gone. Theoretically there is no difference between this one and the shortcut file. In Linux shell rm -rf * does not ask you confirmation. If the user does not know what he/she is doing then he/she should suffer the consequences. Moreover implementing this kind a confirmation on all platforms we support is not a one-man day work. I still think this is too much of a trouble just to protect some user from themselves.

Last edited 5 years ago by gombara (previous) (diff)

comment:4 by Silekonn, 5 years ago

A prompt should exist. My shortcut created for a VM named "Ubuntu" overwrote an existing shortcut. No warning was given and the existing shortcut had nothing to do with VirtualBox. It is not difficult to click Create Desktop Shortcut by accident. The consequence, as socratis explains, is data loss. If you feel warnings are excessive, you should instead move for implementing a "Do not show this prompt again" option (and a reset in preferences).

Last edited 5 years ago by Silekonn (previous) (diff)

in reply to:  4 comment:5 by Socratis, 5 years ago

gombara: implementing this kind a confirmation on all platforms we support is not a one-man day work

Silekonn: If you feel warnings are excessive, you should instead move for implementing a "Do not show this prompt again" option (and a reset in preferences).


Well, then it's definitely going to be more than a one-man day work! :D

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use