From: Ian Jackson Date: Tue, 10 Mar 2020 18:26:16 +0000 (+0000) Subject: make-secnet-sites: Tolerate missing group in userv sites file X-Git-Tag: v0.6.1~16 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=secnet.git;a=commitdiff_plain;h=f96167a2eb285a9ea5d43c69a59062dfc71340d0 make-secnet-sites: Tolerate missing group in userv sites file When processing a sites file fragment via userv, the group in the provided file is supposed to be optional. This was accidentally regressed in 19482a2958fa make-secnet-sites: Do not write out unchecked output in sites The additional call to w[2].groupname ought to have been conditional. Now we have precisely the right code in OpBase, so simply call it. Signed-off-by: Ian Jackson --- diff --git a/make-secnet-sites b/make-secnet-sites index 0520486..85ee7a8 100755 --- a/make-secnet-sites +++ b/make-secnet-sites @@ -375,7 +375,7 @@ class OpUserv(OpBase): sys.exit(1) def check_group(self,group,w): if group!=self.group: complain("Incorrect group!") - w[2].groupname() + OpBase.check_group(self,group,w) def read_in(self): self.headerinput=pfilepath(self.header,allow_include=True) self.userinput=sys.stdin.readlines()