Skip to content

Testing#4

Draft
hramrach wants to merge 15 commits into
developmentfrom
testing
Draft

Testing#4
hramrach wants to merge 15 commits into
developmentfrom
testing

Conversation

@hramrach

Copy link
Copy Markdown
Owner

No description provided.

The bundled strtod parses floats correctly regardless of locale, no need
to reset locale around calling the parser.

It should have been setting LC_CTYPE, anyway.
This will be needed for accessing data of reentrant lexer.

Signed-off-by: Michal Suchanek <msuchanek@suse.de>
The sensors library uses a global config that needs to be initialized
and then cleaned up.

Gather the config into a struct, add a version of the functions that
accept the config to operate on, and use one global config internally to
implement the existing interface.

This is not really reentrant because the parser isn't because the
number parsing isn't because locale isn't, and libc number parsing
cannot be done without locale.

It is sufficient for language runtimes that do user thread switching in
the runtime, and don't interrupt C code. The parser won't be interrupted
in those. In software that uses kernel threads a lock must be held
around the init call.

Signed-off-by: Michal Suchanek <msuchanek@suse.de>
This reverts commit c2047fe9dabb3f10a4b8f5af7aee61e60ca2bc50.
@hramrach

Copy link
Copy Markdown
Owner Author

Coverage after merging testing into master will be

25.10%▾ -1.89%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
lib
   access.c32.39%26.75%46.43%36.10%103, 117, 117, 117–118, 118, 118, 130, 130, 130, 139, 144, 144, 144–145, 145, 145–146, 155–158, 168, 171, 183, 186–187, 187, 187–188, 188, 188–190, 199, 214–215, 228–229, 229, 229–230, 230, 230, 244–245, 245, 245–246, 246, 246, 264, 266, 268, 270, 273, 282, 285–287, 287, 287–289, 289, 289–291, 297, 299, 301, 301, 301, 303, 307, 310, 322, 325, 327, 337, 337, 337, 339, 339, 339, 341, 341, 341, 344, 344, 344, 348, 348, 348, 353, 353, 353, 356, 356, 356–357, 357, 357–358, 358, 358–360, 360, 360–362, 367–368, 368, 368–369, 369, 369, 372, 375, 378, 388, 388, 388, 394, 396, 404, 404, 404, 404, 404, 404, 404, 404, 404, 407–408, 411–416, 419–426, 430, 430, 430–431, 431, 431–432, 432, 432–433, 438, 440, 447, 45, 451–452, 459, 46, 462, 472, 482, 489, 493, 496, 50, 504, 504, 504, 507, 507, 507–508, 508, 508–509, 509, 509, 509, 509, 51, 51, 510–511, 517, 526, 526, 526–528, 530, 530, 530–532, 534, 534, 534–536, 536, 536, 538–539, 542, 542, 542, 545, 545, 545, 545, 545–546, 549, 549, 549, 549, 549, 549, 549, 549, 549, 55, 550–559, 56, 56, 560, 560, 560, 562–571, 571, 571, 573–574, 582, 591, 593, 593, 593–594, 594, 594–597, 597, 597–598, 60, 60, 60, 602, 605–606, 608, 608, 608–609, 61, 61, 61, 611, 613, 615, 615, 615, 617, 619, 621, 624, 629, 63, 631, 633, 639, 639, 639–641, 641, 641, 644, 83–84, 86–87, 87, 87–88, 88, 88–89
   conf-lex.c46.23%41.23%43.59%49.85%1672–1673, 1675–1676, 1678, 1681, 1681–1684, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 1726, 2158, 2162, 2164, 2179, 2182, 2184, 2190, 2248–2249, 2271–2272, 2275, 2277, 2277, 2277, 2290, 2313, 2317, 2319–2320, 2322, 2322, 2322, 2324, 2326, 2326, 2326–2327, 2329, 2331, 2333–2334, 2338, 2340, 2340, 2340–2341, 2344, 2346, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2355, 2380, 2382–2385, 2385, 2385–2386, 2388, 2412, 2428, 2428, 2428, 2523, 2523–2526, 2529, 2547, 2547, 2550, 2550, 2553–2555, 2589–2590, 2598–2599, 2616, 2619, 2619, 2622, 2652, 2652, 2664, 2691, 2694, 2694, 2694, 2697, 2700, 2700, 2700, 2700, 2700, 2703–2705, 2709, 2709, 2709, 2709, 2709–2711, 2714–2715, 2722, 2725, 2725, 2725, 2725, 2725, 2728–2730, 2730, 2730–2731, 2733, 2733, 2733, 2733, 2733–2735, 2747, 2757–2758, 2767, 2767, 2767, 2772–2773, 2777, 2777, 2777–2778, 2781–2782, 2792, 2796, 2796, 2796–2797, 2797, 2797–2798, 2798, 2798, 2802–2803, 2803, 2803–2804, 2806–2814, 2816, 2818, 2829, 2832, 2842, 2850–2852, 2852, 2852–2853, 2855, 2855, 2855–2856, 2858, 2860–2861, 2861, 2861–2862, 2867, 2869, 2876, 2880–2881, 2915, 2919, 2919, 2919, 2919, 2919, 2922, 2928, 2932, 2932, 2932, 2932, 2932, 2935, 2941, 2944, 2950, 2953, 2959, 2962, 2969, 2972, 2989, 2994, 2994, 2994, 2994, 2994–2995, 2997–2998, 3004, 3009, 3009, 3009, 3009, 3009–3010, 3012–3013, 3021, 3024–3025, 3027, 3030–3031, 3033, 3036, 3039, 3042–3043, 3047, 3050, 3053, 3056–3057, 3067–3069, 3074–3076, 3092, 3096, 3098, 3098, 3098–3100, 3103, 3105, 3105, 3105–3107, 3114, 3116, 3158, 3158–3161, 3216, 3228
   conf-lex.l80%50%100%81.58%205–208, 212, 214–215, 219–230, 242–243, 297–298, 327, 348, 352–353, 357–358, 364–367
   conf-parse.c24.57%16.85%100%28.87%1045, 1051, 1074, 1074, 1074–1076, 1083, 1085, 1085, 1085–1088, 1090, 1090, 1090–1091, 1095–1096, 1103, 1103, 1103–1104, 1130, 1136, 1142, 1142, 1142, 1150, 1154, 1154, 1154, 1161, 1161–1162, 1164,

@hramrach hramrach force-pushed the development branch 4 times, most recently from 8a41efc to 0b5fc76 Compare April 27, 2026 07:53
@hramrach hramrach force-pushed the development branch 3 times, most recently from 3ba5942 to cb9a02a Compare May 25, 2026 07:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant