Bug 811799 - manpage does not document whether dynamically allocated memory has to be freed
Summary: manpage does not document whether dynamically allocated memory has to be freed
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: popt
Version: 19
Hardware: All
OS: All
unspecified
unspecified
Target Milestone: ---
Assignee: Robert Scheck
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-04-12 01:54 UTC by Christoph Anton Mitterer
Modified: 2013-11-24 16:49 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-11-24 16:49:52 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Debian BTS 666245 0 None None None Never

Description Christoph Anton Mitterer 2012-04-12 01:54:47 UTC
Hi.

Popt has the options to "automatically update program variables when the option is used".
This is done by the argInfo and arg elements of option tables.


1) For all the pointer types, i.e. POPT_ARG_STRING and POPT_ARG_ARGV it does not document[0],
what kind of memory this is (I guess dynamically allocated) and whether the user has to
free this (I guess so).

This is especially missing in the section "1. THE OPTION TABLE".


2) Again, for all the pointer types, i.e. POPT_ARG_STRING and POPT_ARG_ARGV it does not
document, what happens to the memory previously pointed to by the arg variable.
I guess(!) this is not freed (it could have been dynamically allocated), so it should at
least be documented, that no special care is taken by popt.


Cheers,
Chris.

[0] It does however document in section "3. PARSING THE COMMAND LINE", that the string returned
by  poptGetOptArg() has to be freed by the user.
I guess the same should be the case for the variables set via POPT_ARG_STRING and POPT_ARG_ARGV.

Comment 1 Fedora End Of Life 2013-04-03 17:14:59 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19

Comment 2 Robert Scheck 2013-11-24 16:33:08 UTC
I am very sorry, but I do really not see how I could help here as Fedora is
downstream of popt. But http://rpm5.org/community/popt-devel/0267.html is a
forward of this request to upstream for discussions there.

Comment 3 Robert Scheck 2013-11-24 16:49:52 UTC
Upstream replied to this at http://rpm5.org/community/popt-devel/0271.html -
from my point of view, there is nothing left thus I am closing this report.
In case you disagree with me, feel free to subscribe popt-devel mailing list
at upstream and let us discuss your point directly with upstream.


Note You need to log in before you can comment on or make changes to this bug.