1
0
Fork 0
mirror of git://git.code.sf.net/p/cdesktopenv/code synced 2025-03-09 15:50:02 +00:00

Remove vestigial 3DFS support code (re: f88f302c)

Support for the long-dead 3DFS userland versioning file system was
already removed from ksh93 (although I'd overlooked some minor
things), but libast still supported it. This removes that too.

src/lib/libast/include/fs3d.h,
src/lib/libast/man/fs3d.3,
src/lib/libast/misc/fs3d.c:
- Removed.

bin/package,
src/cmd/INIT/package.sh:
- Remove attempted use of removed vpath builtin.

src/cmd/ksh93/*:
- Remove minor 3dfs vestiges.

src/lib/lib{ast,cmd,coshell}/*:
- Remove code supporting 3dfs.
This commit is contained in:
Martijn Dekker 2020-07-17 04:26:17 +01:00
parent 2db9953ae0
commit fbc6cd4286
32 changed files with 83 additions and 683 deletions

View file

@ -262,10 +262,6 @@ done ${PACKAGE_ast_INCLUDE}/stk.h
make ${PACKAGE_ast_INCLUDE}/hashkey.h implicit
prev ${PACKAGE_ast_INCLUDE}/prototyped.h implicit
done ${PACKAGE_ast_INCLUDE}/hashkey.h
make ${PACKAGE_ast_INCLUDE}/fs3d.h implicit
prev ${PACKAGE_ast_INCLUDE}/ast_fs.h implicit
prev ${PACKAGE_ast_INCLUDE}/prototyped.h implicit
done ${PACKAGE_ast_INCLUDE}/fs3d.h
prev fts_fix.h implicit
prev ${PACKAGE_ast_INCLUDE}/times.h implicit
prev ${PACKAGE_ast_INCLUDE}/ls.h implicit
@ -381,7 +377,6 @@ done rev.h
prev cmd.h implicit
done rev.c
make rm.c
prev ${PACKAGE_ast_INCLUDE}/fs3d.h implicit
prev fts_fix.h implicit
prev ${PACKAGE_ast_INCLUDE}/ls.h implicit
prev cmd.h implicit

View file

@ -134,7 +134,6 @@ static const char usage_tail[] =
#include <ls.h>
#include <times.h>
#include <fts_fix.h>
#include <fs3d.h>
#include <hashkey.h>
#include <stk.h>
#include <tmx.h>
@ -161,11 +160,9 @@ typedef struct State_s /* program state */
int directory; /* destination is directory */
int flags; /* FTS_* flags */
int force; /* force approval */
int fs3d; /* 3d fs enabled */
int hierarchy; /* preserve hierarchy */
int interactive; /* prompt for approval */
int missmode; /* default missing dir mode */
int official; /* move to next view */
int op; /* {CP,LN,MV} */
int perm; /* permissions to preserve */
int postsiz; /* state.path post index */
@ -418,12 +415,8 @@ visit(State_t* state, register FTSENT* ent)
fts_set(NiL, ent, FTS_SKIP);
return 0;
}
else if (!state->fs3d || !iview(&st))
else
{
/*
* target is in top 3d view
*/
if (state->op != LN && st.st_dev == ent->fts_statp->st_dev && st.st_ino == ent->fts_statp->st_ino)
{
if (state->op == MV)
@ -436,8 +429,7 @@ visit(State_t* state, register FTSENT* ent)
sfputr(sfstdout, state->path, '\n');
goto operate;
}
if (!state->official)
error(2, "%s: identical to %s", state->path, ent->fts_path);
error(2, "%s: identical to %s", state->path, ent->fts_path);
return 0;
}
if (S_ISDIR(st.st_mode))
@ -966,8 +958,6 @@ b_cp(int argc, register char** argv, Shbltin_t* context)
error(ERROR_USAGE|4, "%s", optusage(NiL));
if (s && !state->directory)
error(3, "%s: not a directory", file);
if ((state->fs3d = fs3d(FS3D_TEST)) && strmatch(file, "...|*/...|.../*"))
state->official = 1;
state->postsiz = strlen(file);
if (state->pathsiz < roundof(state->postsiz + 2, PATH_CHUNK) && !(state->path = newof(state->path, char, state->pathsiz = roundof(state->postsiz + 2, PATH_CHUNK), 0)))
error(ERROR_SYSTEM|3, "out of space");

View file

@ -70,7 +70,6 @@ USAGE_LICENSE
#include <cmd.h>
#include <ls.h>
#include <fts_fix.h>
#include <fs3d.h>
#define RM_ENTRY 1
@ -86,7 +85,6 @@ typedef struct State_s /* program state */
int clobber; /* clear out file data first */
int directory; /* remove(dir) not rmdir(dir) */
int force; /* force actions */
int fs3d; /* 3d enabled */
int interactive; /* prompt for approval */
int recursive; /* remove subtrees too */
int terminal; /* attached to terminal */
@ -115,8 +113,6 @@ rm(State_t* state, register FTSENT* ent)
if (!state->force)
error(2, "%s: not found", ent->fts_path);
}
else if (state->fs3d && iview(ent->fts_statp))
fts_set(NiL, ent, FTS_SKIP);
else switch (ent->fts_info)
{
case FTS_DNR:
@ -332,12 +328,10 @@ b_rm(int argc, register char** argv, Shbltin_t* context)
State_t state;
FTS* fts;
FTSENT* ent;
int set3d;
cmdinit(argc, argv, context, ERROR_CATALOG, ERROR_NOTIFY);
memset(&state, 0, sizeof(state));
state.context = context;
state.fs3d = fs3d(FS3D_TEST);
state.terminal = isatty(0);
for (;;)
{
@ -396,14 +390,6 @@ b_rm(int argc, register char** argv, Shbltin_t* context)
state.verbose = 0;
state.uid = geteuid();
state.unconditional = state.unconditional && state.recursive && state.force;
if (state.recursive && state.fs3d)
{
set3d = state.fs3d;
state.fs3d = 0;
fs3d(0);
}
else
set3d = 0;
if (fts = fts_open(argv, FTS_PHYSICAL, NiL))
{
while (!sh_checksig(context) && (ent = fts_read(fts)) && !rm(&state, ent));
@ -411,7 +397,5 @@ b_rm(int argc, register char** argv, Shbltin_t* context)
}
else if (!state.force)
error(ERROR_SYSTEM|2, "%s: cannot remove", argv[0]);
if (set3d)
fs3d(set3d);
return error_info.errors != 0;
}