Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accessing unallocated buffer in paramcard_set #4

Closed
tueda opened this issue Mar 15, 2022 · 0 comments
Closed

Accessing unallocated buffer in paramcard_set #4

tueda opened this issue Mar 15, 2022 · 0 comments
Labels
bug Something isn't working

Comments

@tueda
Copy link
Owner

tueda commented Mar 15, 2022

program demo_set
    use paramcard
    implicit none
    call paramcard_set('a', 1)
end program demo_set

gives

At line 1195 of file ./src/paramcard.f90
Fortran runtime error: Index '1' of dimension 1 of array 'tmp_params' outside of expected range (1:0)

Error termination. Backtrace:
#0  0x7feff0c07692 in ???
#1  0x7feff0c08159 in ???
#2  0x7feff0c0876a in ???
#3  0x4065d3 in add_param
        at ./src/paramcard.f90:1195
#4  0x40ced5 in __paramcard_MOD_paramcard_set_str
        at ./src/paramcard.f90:828
#5  0x40c8fa in __paramcard_MOD_paramcard_set_int32
        at ./src/paramcard.f90:872
#6  0x40133c in demo_set
        at example/demo-set.f90:4
#7  0x401378 in main
        at example/demo-set.f90:2
<ERROR> Execution failed for object " demo-set "
<ERROR>*cmd_run*:stopping due to failed executions
STOP 1
@tueda tueda added the bug Something isn't working label Mar 15, 2022
@tueda tueda closed this as completed in 8f29efa Mar 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant