Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!gem.mps.ohio-state.edu!samsung!aplcen!haven!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn) Newsgroups: comp.unix.wizards Subject: Re: calling one varargs routine from another (how?!) Message-ID: <11436@smoke.BRL.MIL> Date: 27 Oct 89 21:08:20 GMT References: <21293@adm.BRL.MIL> Reply-To: gwyn@brl.arpa (Doug Gwyn) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 10 In article <21293@adm.BRL.MIL> mark@spider.co.uk (Mark Valentine) writes: -Q: Is there a portable way, both in ANSI and traditional C, to call a - varargs function such as - void error(char *message, ...) - from another such as - void fatal(char *message, ...) No, the best you can do is for the called function to accept a va_list parameter that the caller initializes via va_start() from its own list. Even then, I've heard of implementations that would do the wrong thing.