Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4041126

java.io.File.delete: NT Permission problem

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P4 P4
    • 7
    • 1.1, 1.1.2
    • core-libs
    • x86
    • windows_nt

      Name: sgC58550 Date: 03/25/97


      Given a NT file with "Full Permissions" set to "Everybody".

      the file:
      File usagers = new File("d:\\java\\httpserver\\outbox.tmp");
      ...
      System.out.println(usagers.canWrite());
      System.out.println(usagers.delete());

      The output is:
      true
      false

      and the file is not deleted.

      If I set the permissions to "none" for "Everybody" and I run the
      same code, the output is:
      true
      true

      and the file is deleted.
      company - Oricom Internet , email - ###@###.###
      ======================================================================

            alanb Alan Bateman
            sgoodsunw Sheri Good (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: