Jump to content

Recommended Posts

Posted

Found interesting error...

Open command line (Start - Run - cmd.exe & enter)

Now create two files - test.txt and test.txt2

echo. > test.txt
echo. > test.txt2

Next use command

del *.txt

It should delete only test.txt file, but instead it deleted both of them...

I found this behavior on many XP machines, mine (5.1.2600.2149) is working as expected (but newer version 5.1.2600.2180 is acting bad way, too)...

How is it working on your PCs?

EDIT: I forgot, same problem with dir command, e.g.

dir *.txt


Posted

It has to do with the way that Windows handles wildcards. I think that it reads the command:

del *.txt

as to delete anything that contains the string ".txt" in it, thereby including test.txt2.

I'm not quite sure as to why the newer version would do this... I can imagine that it might screw up some people's programs...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...