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

pgagroal-cli incompatible (or incomplete) options #278

Closed
fluca1978 opened this issue Jun 20, 2022 · 0 comments · Fixed by #279
Closed

pgagroal-cli incompatible (or incomplete) options #278

fluca1978 opened this issue Jun 20, 2022 · 0 comments · Fixed by #279

Comments

@fluca1978
Copy link
Collaborator

Using pgagroal 019ea11, while working on #253 I discovered by accident that the following seems to work:

$ pgagroal-cli status -U luca -P secret
Status:              Running
Active connections:  0
Total connections:   1
Max connections:     4
Segmentation fault (core dumped)

and also something more interesting that could reveal the issue of the segmentation fault:

$ pgagroal-cli details -U luca -P secret
...
Connection    0:     Free            2022-06-20 07:07:24        21     pgbench pgbench 
Connection    1:     Not initialized                                     
Connection    2:     Not initialized                                     
Connection    3:     Not initialized                                     
free(): invalid pointer
Aborted (core dumped)

The point here is that the -P and -U options should not be taken into account at all when not providing a remote connection information. So the pgagroal-cli program should warn the user that she has mixed arguments.
I suspect also that the core dumped is related to some remote connection information not properly allocated and that is going to be freed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant