My `bitcoin.conf`:
```
$ cat ~/.bitcoin/bitcoin.conf 
[regtest]
blockfilterindex=basic
```
And if I launch `bitcoind` specifying `..=basic` *again*, like this:
```
$ ./bitcoind -chain=regtest -blockfilterindex=basic
```

I get this error (full log below):
```
EXCEPTION: 15dbwrapper_error       
Fatal LevelDB error: IO error: lock /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db/LOCK: already held by process       
bitcoin in AppInit()
```
Does not reproduce if I use `-blockfilterindex=1` twice.

**Expected behavior**

Should not fatal-away due to redundant command line arguments.

**Actual behavior**

`bitcoind` exits with Fatal LevelDB error.

**To reproduce**

* Debian Sid
* `../configure --with-incompatible-bdb --with-gui=no` (`incompatile` to use Debian's bdb)
* Have `bitcoin.conf` as noted before.
* Run `./bitcoind -chain=regtest -blockfilterindex=basic`

**System information**

Bitcoin Core v0.19.0.1 and from current master
Debian Sid amd64.
Same with `bitcoind` and `bitcoin-qt`

Full output:
```
2019-12-05T18:56:30Z Feeding 34499 bytes of environment data into RNG
2019-12-05T18:56:30Z Bitcoin Core version v0.19.99.0-6fff333c9 (release build)
2019-12-05T18:56:30Z Validating signatures for all blocks.
2019-12-05T18:56:30Z Setting nMinimumChainWork=0000000000000000000000000000000000000000000000000000000000000000
2019-12-05T18:56:30Z Using the 'sse4(1way),sse41(4way),avx2(8way)' SHA256 implementation
2019-12-05T18:56:30Z Using RdRand as an additional entropy source
2019-12-05T18:56:30Z Default data directory /home/vincas/.bitcoin
2019-12-05T18:56:30Z Using data directory /home/vincas/.bitcoin/regtest
2019-12-05T18:56:30Z Config file: /home/vincas/.bitcoin/bitcoin.conf
2019-12-05T18:56:30Z Using at most 125 automatic connections (1024 file descriptors available)
2019-12-05T18:56:30Z Using 16 MiB out of 32/2 requested for signature cache, able to store 524288 elements
2019-12-05T18:56:30Z Using 16 MiB out of 32/2 requested for script execution cache, able to store 524288 elements
2019-12-05T18:56:30Z Script verification uses 7 additional threads
2019-12-05T18:56:30Z scheduler thread start
2019-12-05T18:56:30Z HTTP: creating work queue of depth 16
2019-12-05T18:56:30Z No rpcpassword set - using random cookie authentication.
2019-12-05T18:56:30Z Generated RPC authentication cookie /home/vincas/.bitcoin/regtest/.cookie
2019-12-05T18:56:30Z HTTP: starting 4 worker threads
2019-12-05T18:56:30Z Using wallet directory /home/vincas/.bitcoin/regtest/wallets
2019-12-05T18:56:30Z init message: Verifying wallet(s)...
2019-12-05T18:56:30Z Using BerkeleyDB version Berkeley DB 5.3.28: (September  9, 2013)
2019-12-05T18:56:30Z Using wallet /home/vincas/.bitcoin/regtest/wallets
2019-12-05T18:56:30Z BerkeleyEnvironment::Open: LogDir=/home/vincas/.bitcoin/regtest/wallets/database ErrorFile=/home/vincas/.bitcoin/regtest/wallets/db.log
2019-12-05T18:56:30Z init message: Loading banlist...
2019-12-05T18:56:30Z ERROR: DeserializeFileDB: Failed to open file /home/vincas/.bitcoin/regtest/banlist.dat
2019-12-05T18:56:30Z Invalid or missing banlist.dat; recreating
2019-12-05T18:56:30Z Cache configuration:
2019-12-05T18:56:30Z * Using 2.0 MiB for block index database
2019-12-05T18:56:30Z * Using 28.0 MiB for basic block filter index database
2019-12-05T18:56:30Z * Using 28.0 MiB for basic block filter index database
2019-12-05T18:56:30Z * Using 8.0 MiB for chain state database
2019-12-05T18:56:30Z * Using 384.0 MiB for in-memory UTXO set (plus up to 286.1 MiB of unused mempool space)
2019-12-05T18:56:30Z init message: Loading block index...
2019-12-05T18:56:30Z Opening LevelDB in /home/vincas/.bitcoin/regtest/blocks/index
2019-12-05T18:56:30Z Opened LevelDB successfully
2019-12-05T18:56:30Z Using obfuscation key for /home/vincas/.bitcoin/regtest/blocks/index: 0000000000000000
2019-12-05T18:56:30Z LoadBlockIndexDB: last block file = 0
2019-12-05T18:56:30Z LoadBlockIndexDB: last block file info: CBlockFileInfo(blocks=0, size=0, heights=0...0, time=1970-01-01...1970-01-01)
2019-12-05T18:56:30Z Checking all blk files are present...
2019-12-05T18:56:30Z Initializing databases...
2019-12-05T18:56:30Z Pre-allocating up to position 0x1000000 in blk00000.dat
2019-12-05T18:56:30Z Opening LevelDB in /home/vincas/.bitcoin/regtest/chainstate
2019-12-05T18:56:30Z Opened LevelDB successfully
2019-12-05T18:56:30Z Wrote new obfuscate key for /home/vincas/.bitcoin/regtest/chainstate: 531e5e9ac4b7503b
2019-12-05T18:56:30Z Using obfuscation key for /home/vincas/.bitcoin/regtest/chainstate: 531e5e9ac4b7503b
2019-12-05T18:56:30Z init message: Rewinding blocks...
2019-12-05T18:56:30Z  block index              45ms
2019-12-05T18:56:30Z Opening LevelDB in /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db
2019-12-05T18:56:30Z Opened LevelDB successfully
2019-12-05T18:56:30Z Using obfuscation key for /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db: 0000000000000000
2019-12-05T18:56:30Z Opening LevelDB in /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db
2019-12-05T18:56:30Z basic block filter index thread start
2019-12-05T18:56:30Z basic block filter index is enabled
2019-12-05T18:56:30Z basic block filter index thread exit
2019-12-05T18:56:30Z Fatal LevelDB error: IO error: lock /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db/LOCK: already held by process
2019-12-05T18:56:30Z You can use -debug=leveldb to get more complete diagnostic messages
2019-12-05T18:56:30Z 

************************
EXCEPTION: 15dbwrapper_error       
Fatal LevelDB error: IO error: lock /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db/LOCK: already held by process       
bitcoin in AppInit()       



************************
EXCEPTION: 15dbwrapper_error       
Fatal LevelDB error: IO error: lock /home/vincas/.bitcoin/regtest/indexes/blockfilter/basic/db/LOCK: already held by process       
bitcoin in AppInit()       

2019-12-05T18:56:30Z Shutdown: In progress...
2019-12-05T18:56:30Z scheduler thread interrupt
2019-12-05T18:56:30Z Shutdown: done

```
gArgs.AddArg("-reindex-chainstate", "Rebuild chain state from the currently indexed blocks. When in pruning mode or if blocks on disk might be corrupted, use full -reindex instead.", ArgsManager::ALLOW_ANY, OptionsCategory::OPTIONS);
#ifndef WIN32
    gArgs.AddArg("-sysperms", "Create new files with system default permissions, instead of umask 077 (only effective with disabled wallet functionality)", ArgsManager::ALLOW_ANY, OptionsCategory::OPTIONS);
#else
    hidden_args.emplace_back("-sysperms");
#endif
    gArgs.AddArg("-txindex", strprintf("Maintain a full transaction index, used by the getrawtransaction rpc call (default: %u)", DEFAULT_TXINDEX), ArgsManager::ALLOW_ANY, OptionsCategory::OPTIONS);
    gArgs.AddArg("-blockfilterindex=<type>",
                 strprintf("Maintain an index of compact filters by block (default: %s, values: %s).", DEFAULT_BLOCKFILTERINDEX, ListBlockFilterTypes()) +
                 " If <type> is not supplied or if <type> = 1, indexes for all known types are enabled.",
                 ArgsManager::ALLOW_ANY, OptionsCategory::OPTIONS);
    gArgs.AddArg("-addnode=<ip>", "Add a node to connect to and attempt to keep the connection open (see the `addnode` RPC command help for more info). This option can be specified multiple times to add multiple nodes.", ArgsManager::ALLOW_ANY | ArgsManager::NETWORK_ONLY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-banscore=<n>", strprintf("Threshold for disconnecting misbehaving peers (default: %u)", DEFAULT_BANSCORE_THRESHOLD), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-bantime=<n>", strprintf("Number of seconds to keep misbehaving peers from reconnecting (default: %u)", DEFAULT_MISBEHAVING_BANTIME), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-bind=<addr>", "Bind to given address and always listen on it. Use [host]:port notation for IPv6", ArgsManager::ALLOW_ANY | ArgsManager::NETWORK_ONLY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-connect=<ip>", "Connect only to the specified node; -noconnect disables automatic connections (the rules for this peer are the same as for -addnode). This option can be specified multiple times to connect to multiple nodes.", ArgsManager::ALLOW_ANY | ArgsManager::NETWORK_ONLY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-discover", "Discover own IP addresses (default: 1 when listening and no -externalip or -proxy)", ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-dns", strprintf("Allow DNS lookups for -addnode, -seednode and -connect (default: %u)", DEFAULT_NAME_LOOKUP), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-dnsseed", "Query for peer addresses via DNS lookup, if low on addresses (default: 1 unless -connect used)", ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-externalip=<ip>", "Specify your own public address", ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-forcednsseed", strprintf("Always query for peer addresses via DNS lookup (default: %u)", DEFAULT_FORCEDNSSEED), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-listen", "Accept connections from outside (default: 1 if no -proxy or -connect)", ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-listenonion", strprintf("Automatically create Tor hidden service (default: %d)", DEFAULT_LISTEN_ONION), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-maxconnections=<n>", strprintf("Maintain at most <n> connections to peers (default: %u)", DEFAULT_MAX_PEER_CONNECTIONS), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-maxreceivebuffer=<n>", strprintf("Maximum per-connection receive buffer, <n>*1000 bytes (default: %u)", DEFAULT_MAXRECEIVEBUFFER), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-maxsendbuffer=<n>", strprintf("Maximum per-connection send buffer, <n>*1000 bytes (default: %u)", DEFAULT_MAXSENDBUFFER), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-maxtimeadjustment", strprintf("Maximum allowed median peer time offset adjustment. Local perspective of time may be influenced by peers forward or backward by this amount. (default: %u seconds)", DEFAULT_MAX_TIME_ADJUSTMENT), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-maxuploadtarget=<n>", strprintf("Tries to keep outbound traffic under the given target (in MiB per 24h), 0 = no limit (default: %d)", DEFAULT_MAX_UPLOAD_TARGET), ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-onion=<ip:port>", "Use separate SOCKS5 proxy to reach peers via Tor hidden services, set -noonion to disable (default: -proxy)", ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
    gArgs.AddArg("-onlynet=<net>", "Make outgoing connections only through network <net> (ipv4, ipv6 or onion). Incoming connections are not affected by this option. This option can be specified multiple times to allow multiple networks.", ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);