On my Linux Mint 19.1:
```bash
$ umask
0022
```

After the first run of `bitcoin-qt -sysperm=false` the `0700` permissions are expected for both the datadir (`~/.bitcoin`) and the walletdir (`~/.bitcoin/wallets`).

Actually, the directories are created with such access permissions:
```bash
$ stat ~/.bitcoin | grep Uid
Access: (0755/drwxr-xr-x)  Uid: ( 1000/ hebasto)   Gid: ( 1000/ hebasto)
$ stat ~/.bitcoin/wallets | grep Uid
Access: (0755/drwxr-xr-x)  Uid: ( 1000/ hebasto)   Gid: ( 1000/ hebasto)
```

Refs:
- #4286
- #13371
- #13389

NOTE: reading through the initial PR #4286 makes me think it was controversial. Is it a better and simpler way to just get rid of `-sysperm` option? I believe a user who needs this option can easily run `chown` command.
{
    auto sock = Hello();
    const Reply& reply = SendRequestAndGetReply(
        *sock, strprintf("STREAM ACCEPT ID=%s SILENT=false", m_session_id), false);
    const std::string& result = reply.Get("RESULT");
    if (result == "OK") {
        return sock;
    }
    if (result == "INVALID_ID") {
        
        Disconnect();
    }
    throw std::runtime_error(strprintf("\"%s\"", reply.full));
}
void Session::Disconnect()
{
    if (m_control_sock->Get() != INVALID_SOCKET) {
        if (m_session_id.empty()) {
            Log("Destroying incomplete SAM session");
        } else {
            Log("Destroying SAM session %s", m_session_id);
        }
    }
    m_control_sock = std::make_unique<Sock>(INVALID_SOCKET);
    m_session_id.clear();
}
} 
}