summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-10-24 19:10:10 +0200
committerwm4 <wm4@nowhere>2013-10-24 22:50:13 +0200
commitcc235d203d26b242b34d899f89a4ab6d2086ef88 (patch)
tree6119ddbe2d8f14519892cb0f37663a8eeddbd637
parentbbc1469272bce28c670c8e21965d856d1ea1f5d3 (diff)
downloadmpv-cc235d203d26b242b34d899f89a4ab6d2086ef88.tar.bz2
mpv-cc235d203d26b242b34d899f89a4ab6d2086ef88.tar.xz
m_config: cosmetics: make code less verbose
-rw-r--r--mpvcore/m_config.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/mpvcore/m_config.c b/mpvcore/m_config.c
index 96c93f7c28..4ea5b54d17 100644
--- a/mpvcore/m_config.c
+++ b/mpvcore/m_config.c
@@ -606,15 +606,10 @@ int m_config_set_option(struct m_config *config, struct bstr name,
const struct m_option *m_config_get_option(const struct m_config *config,
struct bstr name)
{
- struct m_config_option *co;
-
assert(config != NULL);
- co = m_config_get_co(config, name);
- if (co)
- return co->opt;
- else
- return NULL;
+ struct m_config_option *co = m_config_get_co(config, name);
+ return co ? co->opt : NULL;
}
int m_config_option_requires_param(struct m_config *config, bstr name)