~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/commands.py

Fixed handling of short options not accepted by the command

Show diffs side-by-side

added added

removed removed

Lines of Context:
346
346
                            # into the array
347
347
                            optarg = a[2:]
348
348
            
 
349
                if optname not in cmd_options:
 
350
                    raise BzrOptionError('unknown short option %r for command'
 
351
                        ' %s' % (shortopt, command.name()))
349
352
            if optname in opts:
350
353
                # XXX: Do we ever want to support this, e.g. for -r?
351
354
                raise BzrError('repeated option %r' % a)