Skip to content
Draft

Share #277

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions ci_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ mv -n bin/kgc*.map bin/kgc*.sys _output/gcc/.
mv -n bin/country.sys _output/gcc/.
# GCC share
(
git submodule update --remote share
cd share
git submodule update --init --recursive
git clean -x -d -f
env COMPILER=gcc ./build.sh
)
mv -n share/src/share.com _output/gcc/.
mv -n share/src/share.map _output/gcc/.
cp -p share/src/share.com _output/gcc/.
cp -p share/src/share.map _output/gcc/.

# Open Watcom Environment Setup
export WATCOM=$BUILD_DIR/_watcom
Expand Down Expand Up @@ -95,13 +95,13 @@ if [ -d ${HOME}/.dosemu/drive_c/tc201 ] ; then
mv -n bin/country.sys _output/tc_dos/.
# TC share
(
git submodule update --remote share
cd share
git submodule update --init --recursive
git clean -x -d -f
env COMPILER=tcc2-emu ./build.sh
)
mv -n share/src/share.com _output/tc_dos/.
mv -n share/src/share.map _output/tc_dos/.
cp -p share/src/share.com _output/tc_dos/.
cp -p share/src/share.map _output/tc_dos/.
fi

echo done
27 changes: 17 additions & 10 deletions kernel/int2f.asm
Original file line number Diff line number Diff line change
Expand Up @@ -357,17 +357,24 @@ SHARE_LOCK_UNLOCK:
; STATIC WORD share_is_file_open(const char far *filename) /* pointer to fully qualified filename */
global SHARE_IS_FILE_OPEN
SHARE_IS_FILE_OPEN:
mov si, ds
mov es, si ; save ds
pop ax ; save return address
pop si ; filename
pop ds ; SEG filename
push ax ; restore return address
push bp
mov bp, sp
push si
push ds
lds si, [bp+4] ; DS:SI = filename
mov ax, 0x10a6
int 0x2f ; returns ax
mov si, es ; restore ds
mov ds, si
ret
clc
int 0x2f
jc .notopen ; someone returned an error
cmp ax, 1 ; only an explicit 1 means "open"
je .done
.notopen:
xor ax, ax
.done:
pop ds
pop si
pop bp
ret 4

; Int 2F Multipurpose Remote System Calls
;
Expand Down