Change LGPL-2.1+ to LGPL-2.1-or-later
[platform/upstream/glib.git] / tools / glib.supp
1 # GLib Valgrind suppressions file
2 #
3 # This provides a list of suppressions for all of GLib (including GIO), for all
4 # Valgrind tools (memcheck, drd, helgrind, etc.) for the false positives and
5 # deliberate one-time leaks which GLib causes to be reported when running under
6 # Valgrind.
7 #
8 # When running an application which links to GLib under Valgrind, you can pass
9 # this suppression file to Valgrind using --suppressions=/path/to/glib-2.0.supp.
10 #
11 # http://valgrind.org/docs/manual/manual-core.html#manual-core.suppress
12 #
13 # Note that there is currently no way for Valgrind to load this automatically
14 # (https://bugs.kde.org/show_bug.cgi?id=160905), so the best GLib can currently
15 # do is to install this file as part of its development package.
16 #
17 # This file should be updated if GLib introduces a new deliberate one-time leak,
18 # or another false race positive in Valgrind: please file bugs at:
19 #
20 # https://gitlab.gnome.org/GNOME/glib/issues/new
21
22 {
23         gnutls-init-calloc
24         Memcheck:Leak
25         match-leak-kinds:reachable
26         fun:calloc
27         ...
28         fun:gtls_gnutls_init
29 }
30
31 {
32         gnutls-init-realloc
33         Memcheck:Leak
34         match-leak-kinds:reachable
35         fun:realloc
36         ...
37         fun:gtls_gnutls_init
38 }
39
40 {
41         g-tls-backend-gnutls-init
42         Memcheck:Leak
43         match-leak-kinds:reachable
44         fun:g_once_impl
45         fun:g_tls_backend_gnutls_init
46 }
47
48 {
49         p11-tokens-init
50         Memcheck:Leak
51         match-leak-kinds:reachable
52         fun:calloc
53         ...
54         fun:create_tokens_inlock
55         fun:initialize_module_inlock_reentrant
56 }
57
58 # One-time allocation from libc for getpwnam() results
59 {
60         g-local-vfs-getpwnam
61         Memcheck:Leak
62         match-leak-kinds:reachable
63         fun:malloc
64         ...
65         fun:getpwnam
66         fun:g_local_vfs_parse_name
67 }
68
69 {
70         glib-init-malloc
71         Memcheck:Leak
72         match-leak-kinds:reachable
73         fun:malloc
74         ...
75         fun:g_quark_init
76 }
77
78 {
79         glib-init-calloc
80         Memcheck:Leak
81         match-leak-kinds:reachable
82         fun:calloc
83         ...
84         fun:g_quark_init
85 }
86
87 {
88         gobject-init-malloc
89         Memcheck:Leak
90         match-leak-kinds:reachable
91         fun:malloc
92         ...
93         fun:gobject_init*
94 }
95
96 {
97         gobject-init-realloc
98         Memcheck:Leak
99         match-leak-kinds:reachable
100         fun:realloc
101         ...
102         fun:gobject_init*
103 }
104
105 {
106         gobject-init-calloc
107         Memcheck:Leak
108         match-leak-kinds:possible,reachable
109         fun:calloc
110         ...
111         fun:gobject_init*
112 }
113
114 {
115         g-type-register-dynamic
116         Memcheck:Leak
117         match-leak-kinds:reachable
118         fun:malloc
119         ...
120         fun:g_type_register_dynamic
121 }
122
123 {
124         g-type-register-static
125         Memcheck:Leak
126         match-leak-kinds:possible,reachable
127         fun:malloc
128         ...
129         fun:g_type_register_static
130 }
131
132 {
133         g-type-register-static-realloc
134         Memcheck:Leak
135         match-leak-kinds:possible,reachable
136         fun:realloc
137         ...
138         fun:g_type_register_static
139 }
140
141 {
142         g-type-register-static-calloc
143         Memcheck:Leak
144         match-leak-kinds:possible,reachable
145         fun:calloc
146         ...
147         fun:g_type_register_static
148 }
149
150 {
151         g-type-register-fundamental
152         Memcheck:Leak
153         match-leak-kinds:possible,reachable
154         fun:malloc
155         ...
156         fun:g_type_register_fundamental
157 }
158
159 {
160         g-type-register-fundamental-calloc
161         Memcheck:Leak
162         match-leak-kinds:possible,reachable
163         fun:calloc
164         ...
165         fun:g_type_register_fundamental
166 }
167
168 {
169         g-type-add-interface-dynamic
170         Memcheck:Leak
171         match-leak-kinds:reachable
172         fun:malloc
173         ...
174         fun:g_type_add_interface_dynamic
175 }
176
177 {
178         g-type-add-interface-static
179         Memcheck:Leak
180         match-leak-kinds:reachable
181         fun:malloc
182         ...
183         fun:g_type_add_interface_static
184 }
185
186 {
187         g-type-add-interface-static-realloc
188         Memcheck:Leak
189         match-leak-kinds:reachable
190         fun:realloc
191         ...
192         fun:g_type_add_interface_static
193 }
194
195 {
196         g-type-add-interface-static-calloc
197         Memcheck:Leak
198         match-leak-kinds:reachable
199         fun:calloc
200         ...
201         fun:g_type_add_interface_static
202 }
203
204 {
205         g-test-rand-init
206         Memcheck:Leak
207         match-leak-kinds:reachable
208         fun:calloc
209         ...
210         fun:g_rand_new_with_seed_array
211         fun:test_run_seed
212         ...
213         fun:g_test_run
214 }
215
216 {
217         g-rand-init2
218         Memcheck:Leak
219         match-leak-kinds:reachable
220         fun:calloc
221         ...
222         fun:g_rand_new_with_seed_array
223         ...
224         fun:get_global_random
225 }
226
227 {
228         g-quark-table-new
229         Memcheck:Leak
230         match-leak-kinds:reachable
231         fun:g_hash_table_new
232         ...
233         fun:quark_new
234 }
235
236 {
237         g-quark-table-resize
238         Memcheck:Leak
239         match-leak-kinds:reachable
240         ...
241         fun:g_hash_table_resize
242         ...
243         fun:quark_new
244 }
245
246 {
247         g-type-interface-init
248         Memcheck:Leak
249         match-leak-kinds:reachable
250         fun:malloc
251         ...
252         fun:type_iface_vtable_base_init_Wm
253 }
254
255 {
256         g-type-class-init-calloc
257         Memcheck:Leak
258         match-leak-kinds:reachable
259         fun:calloc
260         ...
261         fun:type_class_init_Wm
262 }
263
264 {
265         g-type-class-init
266         Memcheck:Leak
267         match-leak-kinds:reachable
268         fun:g_type_create_instance
269         ...
270         fun:type_class_init_Wm
271 }
272
273 {
274         g-object-do-class-init-signals
275         Memcheck:Leak
276         match-leak-kinds:reachable
277         ...
278         fun:g_signal_new
279         ...
280         fun:type_class_init_Wm
281 }
282
283 {
284         g-type-prerequisites
285         Memcheck:Leak
286         match-leak-kinds:reachable
287         fun:realloc
288         ...
289         fun:type_iface_add_prerequisite_W
290 }
291
292 {
293         g-type-add-interface-check
294         Memcheck:Leak
295         match-leak-kinds:reachable
296         fun:malloc
297         ...
298         fun:g_type_add_interface_check
299         ...
300         fun:type_class_init_Wm
301 }
302
303 {
304         g-type-add-interface-check-realloc
305         Memcheck:Leak
306         match-leak-kinds:reachable
307         fun:realloc
308         ...
309         fun:g_type_add_interface_check
310         ...
311         fun:type_class_init_Wm
312 }
313
314 {
315         g-object-class-install-property
316         Memcheck:Leak
317         match-leak-kinds:reachable
318         fun:malloc
319         ...
320         fun:validate_and_install_class_property
321         ...
322         fun:type_class_init_Wm
323 }
324
325 {
326         g-param-spec-pool-new
327         Memcheck:Leak
328         match-leak-kinds:reachable
329         fun:malloc
330         ...
331         fun:g_param_spec_pool_new
332         ...
333         fun:type_class_init_Wm
334 }
335
336 # weak_locations_lock in gobject.c
337 {
338         g-weak-ref-lock
339         Memcheck:Leak
340         match-leak-kinds:reachable
341         fun:malloc
342         ...
343         fun:g_rw_lock_get_impl
344         ...
345         fun:g_weak_ref_set
346 }
347
348 {
349         g-object-base-class-init-construct-pproperties
350         Memcheck:Leak
351         match-leak-kinds:reachable
352         fun:malloc
353         ...
354         fun:g_slist_copy
355         fun:g_object_base_class_init
356         fun:type_class_init_Wm
357 }
358
359 {
360         g-type-class-ref
361         Memcheck:Leak
362         fun:calloc
363         ...
364         fun:type_class_init_Wm
365         ...
366         fun:g_type_class_ref
367 }
368
369 {
370         g-type-class-ref-inlined
371         Memcheck:Leak
372         fun:calloc
373         ...
374         fun:UnknownInlinedFun
375         ...
376         fun:g_type_class_ref
377 }
378
379 {
380         g-io-module-default-singleton-malloc
381         Memcheck:Leak
382         match-leak-kinds:reachable
383         fun:malloc
384         ...
385         fun:g_type_create_instance
386         ...
387         fun:_g_io_module_get_default
388 }
389
390 {
391         g-io-module-default-singleton-calloc
392         Memcheck:Leak
393         match-leak-kinds:reachable
394         fun:calloc
395         ...
396         fun:g_type_create_instance
397         ...
398         fun:_g_io_module_get_default
399 }
400
401 # This one seems to show up sometimes with g_type_create_instance() at the top
402 # of the stack, as well.
403 {
404         g-io-module-default-singleton
405         Memcheck:Leak
406         match-leak-kinds:reachable
407         fun:g_type_create_instance
408         ...
409         fun:_g_io_module_get_default
410 }
411
412 {
413         g-io-module-default-singleton-module
414         Memcheck:Leak
415         match-leak-kinds:reachable
416         fun:calloc
417         ...
418         fun:g_module_open
419         ...
420         fun:_g_io_module_get_default
421 }
422
423 {
424         g-io-module-default-singleton-name
425         Memcheck:Leak
426         match-leak-kinds:reachable
427         fun:malloc
428         ...
429         fun:g_strdup
430         ...
431         fun:_g_io_module_get_default*
432 }
433
434 {
435         g-io-module-default-singleton-weak-ref
436         Memcheck:Leak
437         fun:calloc
438         ...
439         fun:_g_io_module_get_default
440 }
441
442 {
443         g-get-language-names-malloc
444         Memcheck:Leak
445         match-leak-kinds:reachable
446         fun:malloc
447         ...
448         fun:g_get_language_names
449 }
450
451 {
452         g-get-language-names-calloc
453         Memcheck:Leak
454         match-leak-kinds:reachable
455         fun:calloc
456         ...
457         fun:g_get_language_names
458 }
459
460 {
461         g-get-language_names-with-category-malloc
462         Memcheck:Leak
463         match-leak-kinds:possible,reachable,definite
464         fun:malloc
465         ...
466         fun:g_get_language_names_with_category
467 }
468
469 {
470         g-get-language_names-with-category-calloc
471         Memcheck:Leak
472         match-leak-kinds:possible,reachable,definite
473         fun:calloc
474         ...
475         fun:g_get_language_names_with_category
476 }
477
478 {
479         g-get-language_names-with-category-realloc
480         Memcheck:Leak
481         match-leak-kinds:possible,reachable,definite
482         fun:realloc
483         ...
484         fun:g_get_language_names_with_category
485 }
486
487 {
488         g-static-mutex
489         Memcheck:Leak
490         match-leak-kinds:reachable
491         fun:malloc
492         ...
493         fun:g_static_mutex_get_mutex_impl
494 }
495
496 {
497         g-system-thread-init
498         Memcheck:Leak
499         match-leak-kinds:possible,reachable
500         fun:calloc
501         ...
502         fun:g_system_thread_new
503 }
504
505 {
506         g-system-thread-init-malloc
507         Memcheck:Leak
508         match-leak-kinds:possible,reachable,definite
509         fun:malloc
510         ...
511         fun:g_system_thread_new
512 }
513
514 {
515         g-task-thread-pool-init
516         Memcheck:Leak
517         match-leak-kinds:possible,reachable,definite
518         fun:malloc
519         ...
520         fun:g_thread_new
521         ...
522         fun:g_task_thread_pool_init
523 }
524
525 {
526         g-io-module-default-proxy-resolver-gnome
527         Memcheck:Leak
528         match-leak-kinds:reachable
529         fun:calloc
530         ...
531         fun:g_proxy_resolver_gnome_init
532         ...
533         fun:_g_io_module_get_default
534 }
535
536 # One-time getaddrinfo() configuration loading
537 {
538         g-threaded-resolver-getaddrinfo-config
539         Memcheck:Leak
540         match-leak-kinds:reachable,definite
541         fun:malloc
542         ...
543         fun:__resolv_conf_allocate
544         ...
545         fun:getaddrinfo
546         fun:do_lookup_by_name
547 }
548
549 # memcheck checks that the third argument to ioctl() is a valid pointer, but
550 # some ioctls use that argument as an integer
551 {
552         ioctl-with-non-pointer-param
553         Memcheck:Param
554         ioctl(generic)
555         fun:ioctl
556         fun:btrfs_reflink_with_progress
557 }
558
559 {
560         g-private-get
561         drd:ConflictingAccess
562         fun:g_private_get
563 }
564 {
565         g-private-get-helgrind
566         Helgrind:Race
567         fun:g_private_get
568 }
569
570
571 {
572         g-private-set
573         drd:ConflictingAccess
574         fun:g_private_set
575 }
576 {
577         g-private-set-helgrind
578         Helgrind:Race
579         fun:g_private_set
580 }
581
582 {
583         g-type-construct-free
584         drd:ConflictingAccess
585         fun:g_type_free_instance
586 }
587 {
588         g-type-construct-free-helgrind
589         Helgrind:Race
590         fun:g_type_free_instance
591 }
592
593 {
594         g-variant-unref
595         drd:ConflictingAccess
596         fun:g_variant_unref
597 }
598 {
599         g-variant-unref-helgrind
600         Helgrind:Race
601         fun:g_variant_unref
602 }
603
604 {
605         g-unix-signals-main
606         drd:ConflictingAccess
607         fun:_g_main_create_unix_signal_watch
608 }
609 {
610         g-unix-signals-dispatch
611         drd:ConflictingAccess
612         ...
613         fun:dispatch_unix_signals*
614 }
615 {
616         g-unix-signals-dispatch-helgrind
617         Helgrind:Race
618         ...
619         fun:dispatch_unix_signals*
620 }
621 {
622         g-unix-signals-other
623         drd:ConflictingAccess
624         fun:g_unix_signal_watch*
625 }
626 {
627         g-unix-signals-other-helgrind
628         Helgrind:Race
629         fun:g_unix_signal_watch*
630 }
631 {
632         g-unix-signals-handler
633         drd:ConflictingAccess
634         fun:g_unix_signal_handler*
635 }
636 {
637         g-unix-signals-handler-helgrind
638         Helgrind:Race
639         fun:g_unix_signal_handler*
640 }
641 {
642         g-unix-signals-worker
643         drd:ConflictingAccess
644         fun:glib_worker_main
645 }
646 {
647         g-unix-signals-worker-helgrind
648         Helgrind:Race
649         fun:glib_worker_main
650 }
651
652 {
653         g-wakeup-acknowledge
654         drd:ConflictingAccess
655         fun:read
656         fun:g_wakeup_acknowledge
657 }
658
659 {
660         g-type-fundamental
661         drd:ConflictingAccess
662         fun:g_type_fundamental
663 }
664 {
665         g-type-fundamental-helgrind
666         Helgrind:Race
667         fun:g_type_fundamental
668 }
669 {
670         g-type-class-peek-static
671         drd:ConflictingAccess
672         fun:g_type_class_peek_static
673 }
674 {
675         g-type-class-peek-static-helgrind
676         Helgrind:Race
677         fun:g_type_class_peek_static
678 }
679 {
680         g-type-is-a
681         drd:ConflictingAccess
682         ...
683         fun:g_type_is_a
684 }
685 {
686         g-type-is-a-helgrind
687         Helgrind:Race
688         ...
689         fun:g_type_is_a
690 }
691
692 {
693         g-inet-address-get-type
694         drd:ConflictingAccess
695         fun:g_inet_address_get_type
696 }
697 {
698         g-inet-address-get-type-helgrind
699         Helgrind:Race
700         fun:g_inet_address_get_type
701 }
702
703 # From: https://github.com/fredericgermain/valgrind/blob/HEAD/glibc-2.X-drd.supp
704 {
705         drd-libc-stdio
706         drd:ConflictingAccess
707         obj:*/lib*/libc-*
708 }
709 {
710         drd-libc-recv
711         drd:ConflictingAccess
712         fun:recv
713 }
714 {
715         drd-libc-send
716         drd:ConflictingAccess
717         fun:send
718 }
719
720 # GSources do an opportunistic ref count check
721 {
722         g-source-set-ready-time
723         drd:ConflictingAccess
724         fun:g_source_set_ready_time
725 }
726 {
727         g-source-set-ready-time-helgrind
728         Helgrind:Race
729         fun:g_source_set_ready_time
730 }
731
732 {
733         g-source-iter-next
734         Helgrind:Race
735         fun:g_source_iter_next
736         fun:g_main_context_*
737         fun:g_main_context_iterate
738 }
739
740 {
741         g-object-instance-private
742         drd:ConflictingAccess
743         fun:*_get_instance_private
744 }
745 {
746         g-object-instance-private-helgrind
747         Helgrind:Race
748         fun:*_get_instance_private
749 }
750
751 # GLib legitimately calls pthread_cond_signal without a mutex held
752 {
753         g-task-thread-complete
754         drd:CondErr
755         ...
756         fun:g_cond_signal
757         fun:g_task_thread_complete
758 }
759 {
760         g-task-thread-complete
761         Helgrind:Misc
762         ...
763         fun:g_cond_signal
764         fun:g_task_thread_complete
765 }
766
767 # False positive, but I can't explain how (FIXME)
768 {
769         g-task-cond
770         Helgrind:Misc
771         ...
772         fun:g_cond_clear
773         fun:g_task_finalize
774 }
775
776 # Real race, but is_cancelled() is an opportunistic function anyway
777 {
778         g-cancellable-is-cancelled
779         Helgrind:Race
780         fun:g_cancellable_is_cancelled
781 }
782
783 # False positive
784 {
785         g-main-context-cond
786         Helgrind:Misc
787         ...
788         fun:g_cond_clear
789         fun:g_main_context_unref
790 }
791
792 # False positives
793 {
794         g-source-unlocked
795         Helgrind:Race
796         fun:g_source_*_unlocked
797 }
798 {
799         g-source-internal
800         Helgrind:Race
801         fun:g_source_*_internal
802 }
803
804 # False positive
805 {
806         g_object_real_dispose
807         Helgrind:Race
808         fun:g_object_real_dispose
809 }
810
811 # False positive
812 {
813         g_object_new_valist
814         Helgrind:Race
815         ...
816         fun:g_object_new_valist
817 }
818
819 # g_set_user_dirs() deliberately leaks the previous cached g_get_user_*() values.
820 # These will not all be reachable on exit.
821 {
822         g_set_user_dirs_str
823         Memcheck:Leak
824         match-leak-kinds:definite,reachable
825         fun:malloc
826         ...
827         fun:set_str_if_different
828         fun:g_set_user_dirs
829 }
830
831 # g_set_user_dirs() deliberately leaks the previous cached g_get_user_*() values.
832 # These will not all be reachable on exit.
833 {
834         g_set_user_dirs_strv
835         Memcheck:Leak
836         match-leak-kinds:definite,reachable
837         fun:malloc
838         ...
839         fun:set_strv_if_different
840         fun:g_set_user_dirs
841 }
842
843 # _g_unset_cached_tmp_dir() deliberately leaks the previous cached g_get_tmp_dir() values.
844 # These will not all be reachable on exit.
845 {
846         g_get_tmp_dir_test_init
847         Memcheck:Leak
848         match-leak-kinds:definite,reachable
849         fun:malloc
850         ...
851         fun:g_get_tmp_dir
852         ...
853         fun:g_test_init
854 }
855
856 # g_get_tmp_dir() caches a one-time allocation
857 {
858         g_get_tmp_dir
859         Memcheck:Leak
860         match-leak-kinds:definite,reachable
861         fun:malloc
862         ...
863         fun:g_get_tmp_dir
864 }
865
866 # g_get_system_data_dirs() caches a one-time allocation
867 {
868         g_get_system_data_dirs
869         Memcheck:Leak
870         match-leak-kinds:reachable
871         fun:malloc
872         ...
873         fun:g_build_system_data_dirs
874         fun:g_get_system_data_dirs
875 }
876
877 # g_get_user_data_dir() caches a one-time allocation
878 {
879         g_get_user_data_dir
880         Memcheck:Leak
881         match-leak-kinds:reachable
882         fun:realloc
883         ...
884         fun:g_build_user_data_dir
885         fun:g_get_user_data_dir
886 }
887
888 # g_get_home_dir() caches a one-time allocation
889 {
890         g_get_home_dir
891         Memcheck:Leak
892         match-leak-kinds:reachable
893         fun:malloc
894         ...
895         fun:g_build_home_dir
896         fun:g_get_home_dir
897 }
898
899 # gdesktopappinfo.c caches a one-time allocation global table of @desktop_file_dirs.
900 {
901         desktop_file_dirs_malloc
902         Memcheck:Leak
903         match-leak-kinds:reachable
904         fun:malloc
905         ...
906         fun:desktop_file_dirs_lock
907 }
908
909 # gdesktopappinfo.c caches a one-time allocation global table of @desktop_file_dirs.
910 {
911         desktop_file_dirs_realloc
912         Memcheck:Leak
913         match-leak-kinds:reachable
914         fun:realloc
915         ...
916         fun:desktop_file_dirs_lock
917 }
918
919 # gdesktopappinfo.c caches a one-time allocation global table of @desktop_file_dirs.
920 {
921         desktop_file_dir_unindexed_setup_search
922         Memcheck:Leak
923         match-leak-kinds:reachable
924         fun:malloc
925         ...
926         fun:desktop_file_dir_unindexed_setup_search
927         fun:desktop_file_dir_unindexed_setup_search
928 }
929
930 #gutils.c caches system and user dirs and may need to replace them during tests.
931 {
932         g_build_user_data_dir
933         Memcheck:Leak
934         match-leak-kinds:definite
935         fun:malloc
936         ...
937         fun:g_build_user_data_dir
938 }
939
940 #gutils.c caches system and user dirs and may need to replace them during tests.
941 {
942         g_build_filename
943         Memcheck:Leak
944         match-leak-kinds:definite
945         fun:malloc
946         ...
947         fun:g_build_filename
948 }
949
950 #gutils.c caches system and user dirs and may need to replace them during tests.
951 {
952         g_build_home_dir
953         Memcheck:Leak
954         match-leak-kinds:definite
955         fun:malloc
956         ...
957         fun:g_build_home_dir
958 }
959
960 #gutils.c caches system and user dirs and may need to replace them during tests.
961 {
962         g_build_path
963         Memcheck:Leak
964         match-leak-kinds:definite
965         fun:malloc
966         ...
967         fun:g_build_path
968 }
969
970 #gutils.c caches system and user dirs and may need to replace them during tests.
971 {
972         g_build_system_config_dirs
973         Memcheck:Leak
974         match-leak-kinds:definite
975         fun:realloc
976         ...
977         fun:g_build_system_config_dirs
978 }
979
980 #gutils.c caches system and user dirs and may need to replace them during tests.
981 {
982         g_build_system_data_dir
983         Memcheck:Leak
984         match-leak-kinds:definite
985         fun:malloc
986         ...
987         fun:g_build_system_data_dir
988 }
989
990 #gutils.c caches system and user dirs and may need to replace them during tests.
991 {
992         g_build_system_data_dirs
993         Memcheck:Leak
994         match-leak-kinds:definite
995         fun:realloc
996         ...
997         fun:g_build_system_data_dirs
998 }
999
1000 #gutils.c caches system and user dirs and may need to replace them during tests.
1001 {
1002         g_build_user_cache_dir
1003         Memcheck:Leak
1004         match-leak-kinds:definite
1005         fun:malloc
1006         ...
1007         fun:g_build_user_cache_dir
1008 }
1009
1010 #gutils.c caches system and user dirs and may need to replace them during tests.
1011 {
1012         g_build_user_config_dir
1013         Memcheck:Leak
1014         match-leak-kinds:definite
1015         fun:malloc
1016         ...
1017         fun:g_build_user_config_dir
1018 }
1019
1020 #gutils.c caches system and user dirs and may need to replace them during tests.
1021 {
1022         g_build_user_data_dir
1023         Memcheck:Leak
1024         match-leak-kinds:definite
1025         fun:malloc
1026         ...
1027         fun:g_build_user_data_dir
1028 }
1029
1030 #gutils.c caches system and user dirs and may need to replace them during tests.
1031 {
1032         g_build_user_runtime_dir
1033         Memcheck:Leak
1034         match-leak-kinds:definite
1035         fun:malloc
1036         ...
1037         fun:g_build_user_runtime_dir
1038 }
1039
1040 #gutils.c caches system and user dirs and may need to replace them during tests.
1041 {
1042         g_build_user_state_dir
1043         Memcheck:Leak
1044         match-leak-kinds:definite
1045         fun:malloc
1046         ...
1047         fun:g_build_user_state_dir
1048 }
1049
1050 # g_io_extension_point_register() caches a one-time allocation global table of @extension_points.
1051 {
1052         g_io_extension_point_register
1053         Memcheck:Leak
1054         match-leak-kinds:reachable
1055         fun:calloc
1056         ...
1057         fun:g_io_extension_point_register
1058 }
1059
1060 # g_strerror() caches a one-time allocation global table of @errors.
1061 {
1062         g_strerror
1063         Memcheck:Leak
1064         match-leak-kinds:reachable
1065         fun:malloc
1066         ...
1067         fun:g_locale_to_utf8
1068         fun:g_strerror
1069 }
1070
1071 # g_socket_connection_factory_register_type() caches a one-time allocation global table of @connection_types.
1072 {
1073         g_socket_connection_factory_register_type
1074         Memcheck:Leak
1075         match-leak-kinds:reachable
1076         fun:calloc
1077         ...
1078         fun:g_socket_connection_factory_register_type
1079 }
1080
1081 # g_dbus_error_quark() never unregisters itself as a GDBusError domain, as it’s always available
1082 {
1083         g_dbus_error_quark
1084         Memcheck:Leak
1085         match-leak-kinds:reachable
1086         fun:calloc
1087         ...
1088         fun:g_dbus_error_register_error_domain
1089         fun:g_dbus_error_quark
1090 }
1091
1092 # g_win32_registry_get_os_dirs_w*() caches an array of strings that is allocated only once.
1093 {
1094         g_win32_registry_get_os_dirs
1095         Memcheck:Leak
1096         match-leak-kinds:reachable,definite
1097         fun:malloc
1098         ...
1099         fun:g_win32_registry_get_os_dirs*
1100 }
1101
1102 # Thread-private data allocated once per thread
1103 {
1104         g_private_set_alloc0
1105         Memcheck:Leak
1106         match-leak-kinds:definite,reachable
1107         fun:malloc
1108         ...
1109         fun:g_private_set_alloc0
1110 }
1111 {
1112         g_private_set_alloc0-calloc
1113         Memcheck:Leak
1114         match-leak-kinds:definite,reachable
1115         fun:calloc
1116         ...
1117         fun:g_private_set_alloc0
1118 }
1119
1120 # Keys for thread-private data
1121 {
1122         g_private_key
1123         Memcheck:Leak
1124         match-leak-kinds:reachable
1125         fun:malloc
1126         fun:g_private_impl_new
1127 }
1128
1129 # Thread-private GMainContext stack
1130 {
1131         g_main_context_push_thread_default
1132         Memcheck:Leak
1133         match-leak-kinds:definite,reachable
1134         fun:malloc
1135         ...
1136         fun:g_queue_new
1137         fun:g_main_context_push_thread_default
1138 }
1139
1140 # One-time allocations for #GFileInfo attribute cache
1141 {
1142         g_file_info_attribute_cache
1143         Memcheck:Leak
1144         match-leak-kinds:reachable
1145         fun:malloc
1146         ...
1147         fun:ensure_attribute_hash
1148         ...
1149         fun:g_file_*
1150 }
1151 {
1152         g_file_info_attribute_cache2
1153         Memcheck:Leak
1154         match-leak-kinds:reachable
1155         fun:calloc
1156         ...
1157         fun:ensure_attribute_hash
1158         ...
1159         fun:g_file_*
1160 }
1161 {
1162         g_file_info_attribute_cache3
1163         Memcheck:Leak
1164         match-leak-kinds:reachable
1165         fun:malloc
1166         ...
1167         fun:lookup_namespace
1168         ...
1169         fun:g_file_*
1170 }
1171 {
1172         g_file_info_attribute_cache4
1173         Memcheck:Leak
1174         match-leak-kinds:reachable
1175         fun:calloc
1176         ...
1177         fun:lookup_namespace
1178         ...
1179         fun:g_file_*
1180 }
1181
1182 # Cached charset
1183 {
1184         g_get_charset
1185         Memcheck:Leak
1186         match-leak-kinds:reachable
1187         fun:malloc
1188         ...
1189         fun:g_get_charset
1190 }
1191
1192 {
1193         g_get_charset_calloc
1194         Memcheck:Leak
1195         match-leak-kinds:reachable
1196         fun:calloc
1197         ...
1198         fun:g_get_charset
1199 }
1200
1201 # Global unused thread queue
1202 {
1203         g_thread_pool_unused_thread_queue
1204         Memcheck:Leak
1205         match-leak-kinds:reachable
1206         fun:malloc
1207         ...
1208         fun:g_async_queue_new_full
1209         ...
1210         fun:g_thread_pool_new
1211 }
1212
1213 # One-time program name storage
1214 {
1215         g_set_prgname
1216         Memcheck:Leak
1217         match-leak-kinds:reachable
1218         fun:malloc
1219         ...
1220         fun:g_set_prgname
1221 }
1222
1223 # Error domains hash
1224 {
1225         g_error_init
1226         Memcheck:Leak
1227         match-leak-kinds: reachable
1228         fun:malloc
1229         ...
1230         fun:g_hash_table_new_full
1231         fun:g_error_init
1232 }
1233
1234 # Error domain static registration
1235 {
1236         g_error_domain_register_static
1237         Memcheck:Leak
1238         match-leak-kinds: reachable
1239         fun:malloc
1240         ...
1241         fun:g_hash_table_insert
1242         fun:error_domain_register
1243         fun:g_error_domain_register_static
1244 }
1245
1246 {
1247         new_quark
1248         Memcheck:Leak
1249         match-leak-kinds:reachable
1250         fun:malloc
1251         ...
1252         fun:g_hash_table_insert
1253         fun:quark_new
1254 }
1255
1256 {
1257         xdg_mime_init_malloc
1258         Memcheck:Leak
1259         fun:malloc
1260         ...
1261         fun:xdg_mime_init
1262 }
1263
1264 {
1265         xdg_mime_init_calloc
1266         Memcheck:Leak
1267         fun:calloc
1268         ...
1269         fun:xdg_mime_init
1270 }