Repository navigation
Port Harbour vf front end and jailed remote driver to current upstream main (stage 5c) - #202
Merged
bedipritpal merged 11 commits intoNov 21, 2026
Conversation
A leading hConn now counts only when numeric AND a live connection (new OAdsIsLiveConnection export, registry-only, no wire traffic). A string first argument is the first documented parameter; 0, .F., NIL and stale numerics are a dead handle slot and fall back to the default connection. Extra trailing arguments are always tolerated and never filled back unless documented. No argument shape raises. FExist/CheckExistence now also expose the raw ACE code via FError(). Adds tests/smoke/harbour/fs_args88.prg conformance probe (+ build script) covering every call form of the family.
…e adaptation as stage 5b)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Harbour vf front end (contrib/oads_hb/oads_vf.c): the vf entry points execute Harbour's own hb_vf* functions by design, so FError rules remain those of the Harbour runtime, with a jailed remote driver (oads_vf_driver.c) mapping tcp:// URIs onto the server and returning the server's error via hb_fsSetError on each round trip. Engine side: hrb_vf service, vf_guard, vf_path, vf_codec wire protocol, session/client wiring, ABI/.def exports. Also validates the leading connection argument across the OAds_* file family (a dead first slot means default connection; a string first argument is the first documented parameter) and carries native platform fixes for link metadata, truncate-open sharing and merged shared opens (posix/win32). The legacy OADS_F* glue keeps its own FError(0)-on-success behaviour. Design note: contrib/oads_hb/VF_PARITY_MTFIX87.txt. No RDD/CDX changes.
Security (existing, reused)
EnableFileFunc gate and resolve_fs_client_path jail unchanged from 5a/5b. Directory aliases pinned within the data root; Windows link-read targets resolved and compared through native metadata handles; the remote driver stays confined to the server data root.
Port
Ten commits cherry-ported from the fork's tested line, messages and author dates preserved: front end + jailed driver, Darwin/Windows metadata pinning, link-target normalization, truncate sharing, merged shared opens, leading-argument validation. Port adaptations: diagnostics-stage open_phase/logging context lines dropped (tracing is a later stage); three wire_caller::Entry lines became the parent arc2_trace hook, the same adaptation as merged 5b; tests/CMakeLists.txt registers only this stage's probes.
Tests
51 files, +3126/-312: Harbour smoke suite vf_87 (front end, local, socket member, TCP locks/extra/bulk/flags/pairs/boundary/compare) and fs_args88 argument-shape conformance; unit tests vf_codec/vf_guard. Local (Linux, gcc -O1 workaround; no local Windows/macOS/clang proof): build green; vf+oads_* doctest 22/22 cases, 476 assertions. Fork CI on the exact port (windows-2022, pinned GCC 15.1 + pinned Harbour 4ec2e154): matched-state vf87 lane green - 18-case front-end suite, matched harness runs=4 cases=18 differences=0 state_not_established=0 under inherited, NUL and pipe stdin, local 29/29, all listed TCP probes PASS, FSARGS88 failures=0: https://github.com/bedipritpal/OpenADS/actions/runs/44905562167 - C++ review lane green: https://github.com/bedipritpal/OpenADS/actions/runs/44905562207
Inherited-stdin note: under inherited stdin the original vf_frontend87 records 2 differences between the observed native and wrapper snapshots (109 on one side, 0 on the other). Diagnostic matrix https://github.com/bedipritpal/OpenADS/actions/runs/44896629849: with inherited stdin the observed pre-Main stores are hb_fsError=hb_fsOsError=109 while FError()=0; the first vfExists captures that incoming state in both call orders (native-first and wrapper-first both record 109); in the tested fixture a subsequent load normalized the stores to 0; NUL and pipe stdin were clean. The matched harness https://github.com/bedipritpal/OpenADS/actions/runs/44901473805 primes and verifies the state before each probe (states {0,2} in both call orders) and shows differences=0 across the 18 cases under inherited/NUL/pipe. Bounded to this evidence: the tested local-existence comparisons show order-state contamination, and the matched 18-case matrix shows parity; no broader claim about wrapper semantics beyond the tested paths.
Validation
This parent port has automated coverage only (see Tests); that is not individual certification of every function or of this port.
Out of scope
Later stages (diagnostics/tracing, mtfix86/mtfix88, hardening, packaging) as separate PRs. The wider GCC 15.1 migration suite runs elsewhere and is not part of this stage