From 0723d1631d28961f219f8be415bd1c489043a600 Mon Sep 17 00:00:00 2001 From: chombier <> Date: Mon, 2 Apr 2001 15:38:10 +0000 Subject: [PATCH] GUSI 2.1.6b3 update --- GUSI/MacDistr | Bin 1157 -> 1176 bytes GUSI/README | Bin 17955 -> 18236 bytes GUSI/src/GUSIFileSpec.nw | Bin 42478 -> 42651 bytes GUSI/src/GUSIMPW.nw | Bin 14785 -> 15247 bytes GUSI/src/GUSIOTNetDB.nw | Bin 9515 -> 9705 bytes GUSI/src/GUSIOpenTransport.nw | Bin 45730 -> 46118 bytes GUSI/src/tangled/GUSIFileSpec.cp | 7 +++++-- GUSI/src/tangled/GUSIMPW.cp | 10 +++++++++- GUSI/src/tangled/GUSIOTNetDB.cp | 9 ++++++--- GUSI/src/tangled/GUSIOpenTransport.cp | 17 +++++++++++++---- macssh/www/download/ChangeLog | Bin 13175 -> 13175 bytes 11 files changed, 33 insertions(+), 10 deletions(-) diff --git a/GUSI/MacDistr b/GUSI/MacDistr index 61fdb25884be628d19b8c2d11f39e308cf6f36ee..2832c173d6543861c93d148358588ebdb81488f9 100755 GIT binary patch delta 135 zcmZqWoWVK4kaH&k0|O@m153q3D|bfYjZH30oGCyd5DuMuk?Er>14D#?{r@@kPmK&1 zSb(C8K+Lf1`5x_U&r7dPzRRp>EbJZ{?5SX+XQ*eEWTa49kdj!E3R1)ZR0~uM(!dBe VGuS^Ug!$5BH5Pfsn8|J|_5kwxALal6 delta 116 zcmbQi*~&S=kaHOW0|O@m154^eD|betjZH30oPj_g5DuMuk?Er>1A}YT4L3*or$z=0 yEI?64AZFNh`ji3)Prl2nsQ?lHN-=_@K(dT*1A_g7LYTTHTe8SAdQOgHu?GPB{TR9c diff --git a/GUSI/README b/GUSI/README index 65cef6dc882e2310420ba4ee43e9ccf9d22f4194..5428a80d3bf5a62486e62c9c8aeae985b9d2d564 100755 GIT binary patch delta 360 zcmZ47!?>r9ae|7N%W(z<1||juS5_b;4rFsOFu2QXvFy!S`&{YV@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I/src/GUSIOTNetDB.nw b/GUSI/src/GUSIOTNetDB.nw index ccedfa4660b6df5426848cb745dd43f3414eaf45..5278d599b0004ab49866ecddb9d190de576a142d 100755 GIT binary patch delta 442 zcmZ4O_0oHSs^onJ1_mYu1{GNb2FCqBHYWpv>K!1hFwxO@V&jf_0|f;m0|P^S0~37% zLj?nKD-$CtBXb3Xywud9OkP!mpw#?=)I5d!JcVrkkbt86vdom!BF|#yoc!X{6kb)Z zin7e&OrQcoJxiEj#`*@93I>)|MkZEE>%46RHJtV}Ew6p}OYbCWVti+EKPJo7S3G81zYGII;^i%K?MWvt<|$V^kvNX}15 zRZz55$o3BjD9SI(Oi3*Y&&P@EBn8Md81WedWSHB|K#KmtH1 cMvxRpmJx15uzyepGt=ZQRe47L$*WZD0R{3s(EtDd diff --git a/GUSI/src/GUSIOpenTransport.nw b/GUSI/src/GUSIOpenTransport.nw index 6c11660b658f40d6f207f6c6f1aa350b032381d2..594318da559db8dd360b1ea27046bbba4a98b2ce 100755 GIT binary patch delta 598 zcmZ4Vlxf)urU@!in`9Um7?>CsHbpToFdhZ6IT;wX$OCDGiH^<_8@KxyDJU2j7#Qjs znCKfADj1ksnV4D`m?}PJG#3XYG^2d`2Hb&`6ZcYl?ti`78MGr zDKU9UItt18DXBUNMXAN5IVGB!)|)j9)^am*Dkx08Vr|FBIa$a?NifZ^xH2!5Gikx8>s+t(qu&^ zwavHl?0HaRz?Ml=UtrZj4i8{(IOpf(0Yfu0FI`Vh4;T(WpYw7SmuHqFXH1@$F29+# zkx!7TII}7>zJ#;5%6hZpq3;T$bf+bD98xJ4BMXX z5#IK^oOANKji$lEAUhR|^bGaPl8h8e3sMqGQbCGXfNFuNK^hq0Mh5!_g)k{GG%(08 gxG^yLhC4X{rG=8SGgE-H9P@|&|ABPI=44>lG#f}OOmuXf*tmW3WX4Z=oA(>6 z=AJC!Dl)m$R%G%t8_~&s%LOLyu@Tz*(B=&5}K8U+hi=bxo7eoIo4R9-LaE>H+`25 ztTkF4WB=61fPn=l#t6g=+fJXd1>wo@n@tr!0zfH7kQ7Lk5v&!+2o3fR3SpQu`S@me L#?Z;nH`@aMV)IZW diff --git a/GUSI/src/tangled/GUSIFileSpec.cp b/GUSI/src/tangled/GUSIFileSpec.cp index 9f87a61..fdd2f98 100755 --- a/GUSI/src/tangled/GUSIFileSpec.cp +++ b/GUSI/src/tangled/GUSIFileSpec.cp @@ -215,12 +215,13 @@ GUSIFileSpec::GUSIFileSpec(const char * path, bool useAlias) while (!fError && *++path == ':') --(*this); } else { - fullSpec = true; if (nextPath = strchr(path, ':')) { AddPathComponent(path, nextPath-path, fullSpec); - path = nextPath+1; + fullSpec = true; + path = nextPath+1; } else { AddPathComponent(path, strlen(path), fullSpec); + fullSpec = true; break; } } @@ -288,6 +289,7 @@ GUSIFileSpec & GUSIFileSpec::operator++() fSpec.vRefNum = 0; fSpec.parID = fsRtParID; fSpec.name[0] = 0; + fValidInfo = false; goto punt; } @@ -326,6 +328,7 @@ GUSIFileSpec & GUSIFileSpec::AddPathComponent(const char * name, int length, boo goto punt; memcpy(fSpec.name+1, name, fSpec.name[0] = length); + fValidInfo = false; if (fSpec.parID == fsRtParID) GetVolume(); diff --git a/GUSI/src/tangled/GUSIMPW.cp b/GUSI/src/tangled/GUSIMPW.cp index 8b051ee..8f40058 100755 --- a/GUSI/src/tangled/GUSIMPW.cp +++ b/GUSI/src/tangled/GUSIMPW.cp @@ -346,7 +346,15 @@ GUSISocket * GUSIMPWDevice::open(GUSIFileToken & file, int flags) if (!ConnectToMPWLibrary()) return GUSISetPosixError(ENOEXEC), static_cast(nil); - int fd = MPW_open(file.Path(), TranslateOpenFlags(flags)); + // To ensure that our fancy path handling gets applied to all complex paths, but MPW gets + // to do its magic on [[Dev:]] paths, we normalize paths if they contain more than 1 colon. + // + // = + const char * path = file.Path(); + const char * colon = strchr(path, ':'); + if (colon && strchr(colon, ':')) + path = file.RelativePath(); + int fd = MPW_open(path, TranslateOpenFlags(flags)); if (fd == -1) { return static_cast(nil); diff --git a/GUSI/src/tangled/GUSIOTNetDB.cp b/GUSI/src/tangled/GUSIOTNetDB.cp index 7327786..f7a6a88 100755 --- a/GUSI/src/tangled/GUSIOTNetDB.cp +++ b/GUSI/src/tangled/GUSIOTNetDB.cp @@ -52,12 +52,15 @@ pascal void GUSIOTNetDBNotify( break; } break; - default: - if (code == kOTProviderWillClose || code == kOTProviderIsClosed) { + switch (code) { + case kOTProviderWillClose: + case kOTProviderIsClosed: netdb->fCreationContext = nil; // Close & reopen - } else { + break; + default: result = 0; + break; } break; } diff --git a/GUSI/src/tangled/GUSIOpenTransport.cp b/GUSI/src/tangled/GUSIOpenTransport.cp index 5e1090e..8400e2d 100755 --- a/GUSI/src/tangled/GUSIOpenTransport.cp +++ b/GUSI/src/tangled/GUSIOpenTransport.cp @@ -23,6 +23,7 @@ inline uint32_t CompleteMask(OTEventCode code) pascal void GUSIOTNotify( GUSIOTSocket * sock, OTEventCode code, OTResult result, void *cookie) { + GUSI_MESSAGE1(("GUSIOTNotify %08x %d\n", code, result)); switch (code & 0x7f000000L) { case 0: sock->fNewEvent |= code; @@ -154,8 +155,9 @@ void GUSIOTSocket::close() // violence to disconnect the socket. // // = - fCompletion &= ~(CompleteMask(T_DISCONNECTCOMPLETE)); - GUSIOTTCall * call = new (fEndpoint, 0) GUSIOTTCall; + fCompletion &= ~(CompleteMask(T_DISCONNECTCOMPLETE)); + GUSIOTTCall * call = new (fEndpoint, 0) GUSIOTTCall; + fAsyncError = 0; SetAsyncMacError(OTSndDisconnect(fEndpoint, call)); delete call; AddContext(); @@ -205,7 +207,8 @@ int GUSIOTSocket::BindToAddress(GUSIOTTBind * addr) fSockName = new (fEndpoint) GUSIOTTBind; if (!fSockName) return GUSISetPosixError(ENOMEM); - fCompletion &= ~CompleteMask(T_BINDCOMPLETE); + fCompletion &= ~CompleteMask(T_BINDCOMPLETE); + fAsyncError = 0; SetAsyncMacError(OTBind(fEndpoint, addr, fSockName)); AddContext(); MopupEvents(); @@ -226,6 +229,7 @@ int GUSIOTSocket::BindToAddress(GUSIOTTBind * addr) void GUSIOTSocket::Unbind() { fCompletion &= ~(CompleteMask(T_BINDCOMPLETE) | CompleteMask(T_UNBINDCOMPLETE)); + fAsyncError = 0; SetAsyncMacError(OTUnbind(fEndpoint)); AddContext(); MopupEvents(); @@ -250,6 +254,7 @@ int GUSIOTSocket::getsockname(void * name, socklen_t * namelen) return GUSISetPosixError(ENOMEM); fCompletion &= ~CompleteMask(T_GETPROTADDRCOMPLETE); + fAsyncError = 0; SetAsyncMacError(OTGetProtAddress(fEndpoint, otname, nil)); AddContext(); @@ -325,7 +330,7 @@ bool GUSIOTSocket::pre_select(bool wantRead, bool wantWrite, bool wantExcept) if (wantRead && OTCountDataBytes(fEndpoint, &sz) == kOTNoDataErr) fEvent &= ~(T_DATA|T_EXDATA); - return true; + return GUSISocket::pre_select(wantRead, wantWrite, wantExcept); } // = int GUSIOTSocket::getsockopt(int level, int optname, void *optval, socklen_t * optlen) @@ -605,6 +610,7 @@ int GUSIOTStreamSocket::listen(int queueLength) else queueLength = ((queueLength * 3) >> 1) + 1; fSockName->qlen = queueLength; + fAsyncError = 0; SetAsyncMacError(OTBind(fEndpoint, fSockName, nil)); AddContext(); MopupEvents(); @@ -672,6 +678,7 @@ if (err) { // = GUSIOTStreamSocket * sock = fNextListener; fCompletion &= ~(CompleteMask(T_ACCEPTCOMPLETE)); + fAsyncError = 0; SetAsyncMacError(OTAccept(fEndpoint, sock->fEndpoint, sock->fPeerName)); AddContext(); MopupEvents(); @@ -721,6 +728,7 @@ int GUSIOTStreamSocket::connect(void * address, socklen_t addrlen) MopupEvents(); OTResult res = 0; + GUSI_MESSAGE(("Connecting...\n")); switch (OTGetEndpointState(fEndpoint)) { case T_OUTCON: if (!fBlocking) @@ -857,6 +865,7 @@ bool GUSIOTStreamSocket::select(bool * canRead, bool * canWrite, bool * except) { MopupEvents(); + size_t sz; bool res = false; OTResult state = OTGetEndpointState(fEndpoint); diff --git a/macssh/www/download/ChangeLog b/macssh/www/download/ChangeLog index 9436b94acb13daee1d3eb8f1a352342390bc3ac0..0604bcf942a9b6f98a21704dc0d8023e23959bf0 100755 GIT binary patch delta 108 zcmeyK_C0Mv3#0MIRvAO-7?nLMm)SoxGGJg~fP!sr)k?O#`RP5m%*bW(0>fP*j6eyd uXABICK+G^d*gq(QxoGk^BR@HYGhi(ZU@`>4{{J7SP>0toWX@zOV_N`=G#`Kf delta 109 zcmeyK_C0Mv3!~A-RvE*|j7B?U7-C)>TDj2vsgVH#3j-8vdsQC2?NwgZ7@bJ=x0G7691bAWHxM