NO

Author Topic: stdio.h and scanf_s  (Read 3352 times)

caan

  • Guest
stdio.h and scanf_s
« on: October 01, 2017, 06:03:31 AM »
Hi
I have included stdio.h in the program but still I get a warning when using scanf_s or printf_s.
/Anders

Offline frankie

  • Global Moderator
  • Member
  • *****
  • Posts: 2113
Re: stdio.h and scanf_s
« Reply #1 on: October 01, 2017, 03:30:44 PM »
You must enable extensions TR24731-1, C11 annex K before including stdio.h.
I.e.
Code: [Select]
#define __STDC_WANT_LIB_EXT1__ 1
#include <stdio.h>

.... //Your code
"It is better to be hated for what you are than to be loved for what you are not." - Andre Gide