Opened 5 years ago

Last modified 3 years ago

#314 reopened enhancement

open x: as DASD not a dir

Reported by: komh Owned by:
Priority: normal Milestone: libc-0.7
Component: libc Version: 0.6.5
Severity: normal Keywords:
Cc:

Description

Hi/2.

open() open x: as a dir. Instead, it would be better to open it as DASD.

Attachments (2)

dasd.diff (3.9 KB) - added by komh 5 years ago.
patch for dasd open
dasd-v2.diff (5.9 KB) - added by komh 3 years ago.
v2 patch for dasd open

Download all attachments as: .zip

Change History (5)

Changed 5 years ago by komh

patch for dasd open

comment:1 Changed 4 years ago by bird

  • Resolution set to wontfix
  • Status changed from new to closed

The current idea of mapping "c:" to what on linux would be something like /dev/sda1 is too risky. An unlucky user with thick fingers may easily get overwhelmed by cat c: or killed by cat d: > c: (if permitted).

I would happily add virtual /dev/something aliases for doing DosOpenL("C:", DASD) without additional open() flags as this requires extra typing, instead of less typing on the user part. If there is a free open flag bit, we could also extend open() to do DASD mode for "drive:" style paths, though I'm not sure there is a free bit and we could just as well add a different API since it requires anyone wanting to use the feature to modify her/his code.

comment:2 Changed 3 years ago by komh

  • Resolution wontfix deleted
  • Status changed from closed to reopened

It would be good to implement this with /dev/drivex mapping, where x is a, b, c, and so on.

Changed 3 years ago by komh

v2 patch for dasd open

comment:3 Changed 3 years ago by komh

This patch opens a drive in DASD mode if the given name is /dev/driveX style. But its real name will be X:. For example, __libc_Back_ioFHToPath returns X: if a given fd was opened with /dev/driveX.

Note: See TracTickets for help on using tickets.