Commit 525789cd authored by Max Kellermann's avatar Max Kellermann

db/simple/Directory: make variables more local

parent 367d660c
......@@ -194,13 +194,11 @@ Directory::FindSong(const char *name_utf8) const
Song *
Directory::LookupSong(const char *uri)
{
char *duplicated, *base;
assert(holding_db_lock());
assert(uri != nullptr);
duplicated = xstrdup(uri);
base = strrchr(duplicated, '/');
char *duplicated = xstrdup(uri);
char *base = strrchr(duplicated, '/');
Directory *d = this;
if (base != nullptr) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment