[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH for-4.15 2/2] tools/xenstore: Check the format printf for xprintf() and barf{,_perror}()



Hi Ian,

On 05/03/2021 13:27, Ian Jackson wrote:
Jürgen Groß writes ("Re: [PATCH for-4.15 2/2] tools/xenstore: Check the format 
printf for xprintf() and barf{,_perror}()"):
On 05.03.21 13:40, Julien Grall wrote:
-extern void (*xprintf)(const char *fmt, ...);
+void barf(const char *fmt, ...) __noreturn PRINTF_ATTRIBUTE(1, 2);
+void barf_perror(const char *fmt, ...) __noreturn PRINTF_ATTRIBUTE(1, 2);
+
+extern void (*xprintf)(const char *fmt, ...) PRINTF_ATTRIBUTE(1, 2);

... the extern here would be dropped.

With my RM hat on I don't have an opinion on that and my R-A can
stand.

With my maintainer hat on I agree with Jürgen's style opinion - it's
nicer without the "extern", but I'm also happy with the patch as is.
I agree with Juergen's style opinion. I will do the modification on commit. I will also update the last sentence of the commit to:

"
Take the opportunity to:
   * remove extern from the function prototype for consistency
   * define __noreturn to make the prototype for
barf{,_perror})() easier to read.
"

Cheers,

Ian.


--
Julien Grall



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.