delorie.com/archives/browse.cgi | search |
Date: | Mon, 08 Jan 2001 00:41:23 +0200 |
From: | "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il> |
Sender: | halo1 AT zahav DOT net DOT il |
To: | lauras AT softhome DOT net |
Message-Id: | <6480-Mon08Jan2001004123+0200-eliz@is.elta.co.il> |
X-Mailer: | Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.6 |
CC: | djgpp-workers AT delorie DOT com, rich AT phekda DOT freeserve DOT co DOT uk |
In-reply-to: | <20010107225557.A210@lauras.lt> |
Subject: | Re: Bug in lstat() - wrong arguments to FSEXT |
References: | <20010107141016 DOT A314 AT lauras DOT lt> <Pine DOT SUN DOT 3 DOT 91 DOT 1010107141348 DOT 25836D-100000 AT is> <20010107155532 DOT A4259 AT lauras DOT lt> <9003-Sun07Jan2001194450+0200-eliz AT is DOT elta DOT co DOT il> <20010107225557 DOT A210 AT lauras DOT lt> |
Reply-To: | djgpp-workers AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | djgpp-workers AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
> From: lauras AT softhome DOT net > Date: Sun, 7 Jan 2001 22:55:57 +0200 > > On Sun, Jan 07, 2001 at 07:44:51PM +0200, Eli Zaretskii wrote: > > if (!__solve_dir_symlinks(path, real_path)) > > return -1; > > > static int try_fsext (int *ret, const char *path, struct stat *statbuf) > > { > > return __FSEXT_call_open_handlers (__FSEXT_stat, ret, &path); > > } > > Why are you passing statbuf arg here? Where it is used? Am I > missing something? Yes, you are missing the fact that the stat hook needs the struct stat buffer as well, to fill it with data. The way it works is that the hook gets a pointer to its first argument on the stack, and then it walks the stack with va_arg to get the rest. The same is done in the open hook: it only gets the pointer to the first argument, but it also needs the open mode.
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |