• Please review our updated Terms and Rules here

cp/m 2.2 public files

jlang

Experienced Member
Joined
Sep 25, 2014
Messages
229
Location
central florida
I have found a lot of references to a patch to CP/M 2.2 to allow public files.
Nowhere have I found the patch for this. Anybody have it?

joe lang
 
Ah, so it's just a bit in the directory attributes that prevents a file from being accessed using wildcard notation. Never noticed that one before--the usual procedure is just to put "protected" files in a different user area or by giving files the R/O attribute with STAT.
 
Thank you krebizfan. I think that's what I was looking for.

Chuck
The user number is pretty flawed. It divides files into "subdirectories" to reduce clutter. (badly) Only showing files that belong to the current user number.
This has the side effect of requiring each user to have a copy of common files under the current user number.
Public files are a way of fixing that by allowing any file with the public bit set to be available under any user number.
CP/M 2.2 has user numbers but not public files.

joe
 
MP/M had a similar feature that was more of a necessity, since several users could be logged on simultaneously, each with a different user area. Given that CP/M is a single-user system, the need for the same feature is less obvious.

So "public files' don't show up with DIR commands, unless the exact file name is specified?
----
(digression)

It's an interesting problem shared by a lot of operating systems. One system that I worked with started each session/job with no user-local files. At end of session, local files were all disposed of (i.e. printed or punched or deleted). If one needed a common shared (permanent) file, it would have to be attached to the session and given a local name and would be detached at the end of session. Of course, user-specific passwords were provided for each permission granted (read/write/execute). A local file could be made permanent by explicitly cataloging it with a distinct "catalog" name. There wasn't a lot of cross-contamination. System files were maintained under a separate management system and could not be easily changed (deleted or created).
 
Last edited:
Another method for cross user area file access under CP/M can be found at http://www.retroarchive.org/cpm/cdrom/CPM/CCP/ as 22PUBLIC.ASM. This one is more like PATH which searches A: and USER 0 for a specified file that can't be found on the starting drive and user area. Reading the 22PUBLIC.BUG should be done as a warning of how invisibly searching different user areas can go wrong.

The bug is that, if the file is greater than 16k (one extent)
the BDOS looks for the next extent in the WRONG user area!
 
Back
Top