Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5138958c authored by Elliott Hughes's avatar Elliott Hughes Committed by Gerrit Code Review
Browse files

Merge "Enable property expansion for insmod"

parents 14799c62 ac41230c
Loading
Loading
Loading
Loading
+10 −1
Original line number Original line Diff line number Diff line
@@ -58,7 +58,16 @@ extern "C" int init_module(void *, unsigned long, const char *);
static int insmod(const char *filename, char *options)
static int insmod(const char *filename, char *options)
{
{
    std::string module;
    std::string module;
    if (!read_file(filename, &module)) {
    char filename_val[PROP_VALUE_MAX];
    int ret;

    ret = expand_props(filename_val, filename, sizeof(filename_val));
    if (ret) {
        ERROR("insmod: cannot expand '%s'\n", filename);
        return -EINVAL;
    }

    if (!read_file(filename_val, &module)) {
        return -1;
        return -1;
    }
    }