Control C does not cancel the CLI cleanly
When a user attempts to terminate the CLI with CTL+C a stack trace is printed to the screen. When downloading files the partial amount downloaded will not be cleaned up. In most cases the user redirects to stdout, thus this program cannot clean that up. Fixes Bug: 1130390 Change-Id: If9f8ffc72b422d5dbd5969eecde8904238dd8860
This commit is contained in:
@@ -440,6 +440,9 @@ class OpenStackImagesShell(object):
|
||||
args.func(client, args)
|
||||
except exc.Unauthorized:
|
||||
raise exc.CommandError("Invalid OpenStack Identity credentials.")
|
||||
except KeyboardInterrupt:
|
||||
LOG.warn('... terminating glance client')
|
||||
sys.exit(1)
|
||||
|
||||
@utils.arg('command', metavar='<subcommand>', nargs='?',
|
||||
help='Display help for <subcommand>')
|
||||
|
||||
Reference in New Issue
Block a user