Skip to content

Commit

Permalink
properly pass the signal name
Browse files Browse the repository at this point in the history
  • Loading branch information
thomas-mangin committed Jul 14, 2024
1 parent 8ba28e7 commit 06f95d7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions qa/sbin/bgp
Original file line number Diff line number Diff line change
Expand Up @@ -97,13 +97,13 @@ def cdr_to_length(cidr):
return 0


def kill(skip, signal_name='SIGUSR1'):
def kill(signal_name='SIGUSR1'):
names = [name for name in dir(signal) if name.startswith('SIG')]
signals = dict([(name, getattr(signal, name)) for name in names])
number = signals.get(signal_name, '')
number = signals.get(signal_name.upper(), '')

if not number:
raise f'invalid signal name: {signal_name}'
raise ValueError(f'invalid signal name: {signal_name}')

# --view is argv[1]
conf_name = sys.argv[2].split('/')[-1].split('.')[0]
Expand Down

0 comments on commit 06f95d7

Please sign in to comment.