]> xenbits.xensource.com Git - libvirt.git/commitdiff
build-aux: only forbid gethostname in C files
authorDaniel P. Berrangé <berrange@redhat.com>
Fri, 7 Jan 2022 16:29:36 +0000 (16:29 +0000)
committerDaniel P. Berrangé <berrange@redhat.com>
Tue, 15 Nov 2022 11:09:30 +0000 (11:09 +0000)
This function is fine to use in other languages

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
build-aux/syntax-check.mk

index 68cd9dff5f0afa313b2df666b3a73c71f06e5ee7..e1d80bd5364762b5420a4c8c6be07fcb82066835 100644 (file)
@@ -203,6 +203,7 @@ sc_prohibit_readlink:
 
 sc_prohibit_gethostname:
        @prohibit='gethostname *\(' \
+       in_vc_files='\.[ch]$$' \
        halt='use virGetHostname, not gethostname' \
          $(_sc_search_regexp)