Opened 14 years ago

#1822 new defect

config parser, "option=false" doesn't work in profiles

Reported by: bugmenot@… Owned by: reimar
Priority: normal Component: core
Version: HEAD Severity: normal
Keywords: Cc:
Blocked By: Blocking:
Reproduced by developer: no Analyzed by developer: no

Description

There are two ways to disable an option in mplayer config. Either use
option with no' prefix and set it to 1' (yes/true) or set just set
it to `0' (no/false).

nooption = true
option = false

This is true for `default' (implicit) profile. But it doesn't work for
other profiles. Consider below example

[foo]
quiet = false

Invoking `mplayer -profile foo' wouldn't show status line.
The workaround is to use `no' prefix.

[foo]
noquiet = true

With a bit of testing one can conclude that for profile `foo'

quiet = false' is equal to quiet = true' and sets
noquiet = true' is equal to noquiet = false'

So, assuming config parser disregards value for boolean options in
profiles it's ironic that it still expects them to be valid

$ mplayer -profile foo
Invalid parameter for quiet flag: blah
Error parsing option quiet=blah at line 2

Change History (0)

Note: See TracTickets for help on using tickets.