From d7153d69570852e82e321e1928619324d66d93d6 Mon Sep 17 00:00:00 2001 From: Sebastien GODARD Date: Mon, 21 Mar 2016 17:50:27 +0100 Subject: [PATCH] SVG: Make SVG code locale independent Graphs could not be displayed if corresponding SVG code had been generated on machines with specific locales. Eg: If you set your locale to, say, fr_FR then here is a sample SVG code you could get: ... /* For setlocale() */ #ifdef USE_NLS -# include # include # define _(string) gettext(string) #else @@ -1284,6 +1284,9 @@ void logic3_display_loop(int ifd, struct file_activity *file_actlst, __nr_t cpu_ int graph_nr = 0; __nr_t save_act_nr[NR_ACT] = {0}; + /* Use a decimal point to make SVG code locale independent */ + setlocale(LC_NUMERIC, "C"); + /* Calculate the number of graphs to display */ graph_nr = get_svg_graph_nr(ifd, file, file_magic, file_actlst, rectime, loctime); -- 2.40.0