Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sample.eng.ohio-state.edu!purdue!haven.umd.edu!socrates.umd.edu!cm315a From: cm315a@socrates.umd.edu (cmis 315 section 4011) Newsgroups: comp.lang.c Subject: Prototyping Question Keywords: Prototype Message-ID: <1991Jun14.122200.3710@socrates.umd.edu> Date: 14 Jun 91 12:22:00 GMT Organization: University of Maryland, University College Lines: 17 Here's a question on prototyping that has me (and the compiler) baffled. I have a function that takes one, or more parameters. If I decalre it as: void funct(char *, ... ) the calls to it with one or two (or more) parameters passes without errors, but when the compiler comes to the function itself, I get an error - not enough parameters. But on the otherhand if I declare it as: void funct(char *, int), the calls to the function with one parameter cause an error. Yes, the prototype, the calls, and the definition of the function are in the same file, or use the same header.h file as the declaration. How does one get around this type of behavior? For the curious, it is a call to an error handler, the error message, and an optional error number - much like a printf() call. - mike cm315a@socrates.umd.edu [