[Bug 648517] Review Request: enum - Seq- and jot-like enumerator

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Please do not reply directly to this email. All additional
comments should be made in the comments box of this bug.


https://bugzilla.redhat.com/show_bug.cgi?id=648517

--- Comment #1 from Kamil Dudka <kdudka@xxxxxxxxxx> 2010-11-02 07:59:35 EDT ---
The following patch eliminates a compile-time warning and undefined behavior in
case of OOM:

diff --git a/src/parsing.c b/src/parsing.c
--- a/src/parsing.c
+++ b/src/parsing.c
@@ -761,8 +761,7 @@ int parse_parameters(unsigned int original_argc, char
**original_argv, scaffoldi

                                prepare_setting_format(dest, APPLY_FORMAT);

-                               escape_strdup(optarg, '%', &newformat);
-                               if (newformat == NULL) {
+                               if (! escape_strdup(optarg, '%', &newformat)) {
                                       
report_parameter_error(PARAMETER_ERROR_OUT_OF_MEMORY);
                                        success = 0;
                                } else {

-- 
Configure bugmail: https://bugzilla.redhat.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
package-review mailing list
package-review@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/package-review


[Index of Archives]     [Fedora Legacy]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]     [Fedora Tools]