Opened 12 years ago
Closed 12 years ago
#10481 closed Patch - Bug Fix (fixed)
Correct empty body warning in metadatafactory.cpp
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | minor | Milestone: | 0.25 |
Component: | MythTV - General | Version: | Unspecified |
Severity: | medium | Keywords: | |
Cc: | Ticket locked: | no |
Description
In metadatafactory.cpp there is a detected (by clang) if statement with an empty body of the form:
if (metadata);
Lookup(metadata, true, true);
such that the Lookup function is called regardless of the value of metadata. It appears that at some point in the past the Lookup function was changed to check for a NULL input, and return immediately, so the check is not technically required. However, for belt and suspenders purposes, I am providing a patch that simply removes the ';', so that the check for NULL will occur in this code (and is what I suspect was the intended purpose of the if).
Thanks.
Gary
Attachments (1)
Change History (2)
Changed 12 years ago by
Attachment: | metadatafactory_cpp.diff added |
---|
comment:1 Changed 12 years ago by
Milestone: | unknown → 0.25 |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Remove extraneous ; in MetadataFactory?.
Gary came up with an explanation that makes the author (me) sound much better than what actually probably occurred, which is my fingers working on autopilot.
Behavior should be totally unchanged.
Fixes #10481.