title: How to determine size of va_args before vsprintf
body: <p>I have a function which takes variable parameters. I am not sure about the size of the parameters during compilation. Now I need to copy all those parameter to character array. </p>
  
  <p>How can we determine the size of the variable parameters before usage of vsprintf? Or is it good idea to copy it to char *?</p>
  
  <pre><code>event(const unsigned int xyz, const char abc[], ...)
  {
      //How can I determine the value of MaxLength
      char formatted_arg[MaxLength]= {'\0'};
      va_list args;
      va_start(args, format_str);
          vsprint(formatted_arg,format_str,args);
      va_end(args);
      return formatted_arg;
  }
  </code></pre>