Yes, I did. These are the included headers:
Code:
#include <linux/module.h>
#include <linux/types.h>
#include <linux/string.h>
#include <linux/ctype.h>
#include <linux/kernel.h>
#include <stdarg.h>
#include <asm/page.h> /* for PAGE_SIZE */
#include <asm/div64.h>
The function in question in mathlib.c is a simple function:
Code:
void float2string(char string*, float num){
sprintf(tring, "%d.%lld\n",(int)num,(long long int)((float) (num-(long long int) num))*1000);
}
The same happens commenting the sprintf function and using (just for the case) "strcpy(string, "SomeString")". Everything is ok if I do:
Quote:
string[0]='1'; string[1]='2'; .... string[n]='\0';
|
or, like I said, if I use the functions defined in vsnprintf.c (namely, sprintf) directly in the main.c file.
Sorry to bother for such a stupid problem, but I spent two days trying to figure out what's wrong. I want to be sure that it is neither a configuration issue nor a programming one.
Thanks, for the interest.
Alessandro