Skip to content

Repeated execution of run_glm causes crash #22

Description

@rqthomas

Because of the following code

 Sys.setenv(DYLD_LIBRARY_PATH = paste(system.file("extbin/nixGLM", 
                                        package = packageName()), 
                                   Sys.getenv("DYLD_LIBRARY_PATH"), 
                                 sep = ":"))

the current environment is appended to the DYLD_LIBRARY_PATH. This results in an exponentially increasing environment variable that max out the limit for the environment variable if run_glm is executed repeatedly (as done in data assimilation with FLARE). Is there a need for this code in both the unix and Mac executions? I have removed it and used the following

 dylib_path <- system.file("exec", package = packageName())  

and

                       stderr = NULL, args = system.args, env = paste0("DYLD_LIBRARY_PATH=", dylib_path))

The Mac execution already does this but the Unix did not (so we were crashing on unix FLARE runs). I can do a PR with the fixes if helpful.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions