Opened on 12/01/11 at 01:43:10
Last modified on 10/10/17 at 06:35:44
#1976 closed defect (fixed)
c/src/libchip/serial/z85c30.c:707:18: warning: variable 'ulCtrlPort2' set but not used
Reported by: | Ralf Corsepius | Owned by: | Joel Sherrill |
---|---|---|---|
Priority: | normal | Milestone: | 4.11 |
Component: | unspecified | Version: | 4.11 |
Severity: | normal | Keywords: | |
Cc: | gedare@… | Blocked By: | |
Blocking: |
Description
GCC raises the warning from the subject, which is pointing to this code:
...
Z85C30_STATIC void z85c30_initialize_interrupts(
int minor
)
{
uint32_t ulCtrlPort1;
uint32_t ulCtrlPort2;
setRegister_f setReg;
ulCtrlPort1 = Console_Port_Tbl[minor]->ulCtrlPort1;
ulCtrlPort2 = Console_Port_Tbl[minor]->ulCtrlPort2;
setReg = Console_Port_Tbl[minor]->setRegister;
...
=> ulCtrlPort2 is not used.
Removing the 2 lines referring to ulCtrlPort2 would silence GCC,
but I am not sure if this warning actually points to a defect.
It seems to me, as if the original author of this code had wanted to initialize something related to "ulCtrlPort2", which was never implemented, lost or else throughout this file's history - I don't know.
Change History (3)
comment:1 Changed on 04/12/14 at 00:30:42 by Gedare Bloom
Resolution: | → fixed |
---|---|
Status: | new → closed, gedare@rtems.org |
comment:2 Changed on 11/24/14 at 18:58:28 by Gedare Bloom
Version: | HEAD → 4.11 |
---|
Replace Version=HEAD with Version=4.11 for the tickets with Milestone >= 4.11
comment:3 Changed on 10/10/17 at 06:35:44 by Sebastian Huber
Component: | misc → unspecified |
---|
Someone removed the lines.