Open maska989 opened 1 year ago
While using the output size modifier with scanf it returned status -1 but according to POSIX:
-1
Code to reproduction:
#include <stdio.h>
int main(void) {
float flt = 3.123412341234e+17, fltVal, fltValSup; char buff[50]; sprintf(buff, "%f", flt); printf("\nscanf = %d\n", sscanf(buff, "%5f %f", &fltVal, &fltValSup)); printf("\n%f %f \n", fltVal, fltValSup);
}
* Output between host-generic-pc and ia32-generic-qemu: ![Screenshot from 2023-04-05 09-08-03](https://user-images.githubusercontent.com/49757239/230006677-3df1cb10-274a-4c3c-b4e1-f08ce70e9c35.png)
https://github.com/phoenix-rtos/phoenix-rtos-tests/blob/c13ef424dff7c1f0f88f02e4a67104f6d9ed5d22/libc/stdio_scanf.c#L4536
While using the output size modifier with scanf it returned status
-1
but according to POSIX:Code to reproduction:
int main(void) {
}