mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-21 20:15:17 +00:00
syntax-check: Simplify and fix unmarked_diagnostics
The check was concerning itself with whitespace where it didn't need to, and used some confusing escaping for one of its regular expressions - which GNU sed was fine with, but FreeBSD's sed didn't like one bit. Switch to extended regular expressions (which, incidentally, were already in use in the same rule when calling grep) and remove all whitespace handling. Signed-off-by: Andrea Bolognani <abologna@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
5c7bfc6b53
commit
4abd8d01cd
4
cfg.mk
4
cfg.mk
@ -643,8 +643,8 @@ sc_libvirt_unmarked_diagnostics:
|
||||
$(GREP) -nE '\<$(func_re) *\(.*;$$' /dev/null; \
|
||||
$(VC_LIST_EXCEPT) | xargs \
|
||||
$(GREP) -A1 -nE '\<$(func_re) *\(.*,$$' /dev/null; } \
|
||||
| $(SED) 's/_("\([^\"]\|\\.\)\+"//;s/[ ]"%s"//' \
|
||||
| $(GREP) '[ ]"' && \
|
||||
| $(SED) -E 's/_\("([^\"]|\\.)+"//;s/"%s"//' \
|
||||
| $(GREP) '"' && \
|
||||
{ echo '$(ME): found unmarked diagnostic(s)' 1>&2; \
|
||||
exit 1; } || :
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user