* [PATCH] isdn: mISDN: dsp_cmx.c: Cleaning up a define that is no longer available
@ 2014-06-06 23:25 Rickard Strandqvist
2014-06-06 23:28 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Rickard Strandqvist @ 2014-06-06 23:25 UTC (permalink / raw)
To: Karsten Keil, Rickard Strandqvist; +Cc: netdev, linux-kernel
Removes an ifdef that is no longer available,
and that would cause a compile error if it was activated.
This was partly found using a static code analysis program called cppcheck.
Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
---
drivers/isdn/mISDN/dsp_cmx.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/isdn/mISDN/dsp_cmx.c b/drivers/isdn/mISDN/dsp_cmx.c
index a4f05c5..9e9bdc0 100644
--- a/drivers/isdn/mISDN/dsp_cmx.c
+++ b/drivers/isdn/mISDN/dsp_cmx.c
@@ -1511,9 +1511,6 @@ dsp_cmx_send_member(struct dsp *dsp, int len, s32 *c, int members)
dsp->tx_R = t;
goto send_packet;
}
-#ifdef DSP_NEVER_DEFINED
- }
-#endif
/* PROCESS DATA (three or more members) */
/* -> if echo is NOT enabled */
if (!dsp->echo.software) {
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] isdn: mISDN: dsp_cmx.c: Cleaning up a define that is no longer available
2014-06-06 23:25 [PATCH] isdn: mISDN: dsp_cmx.c: Cleaning up a define that is no longer available Rickard Strandqvist
@ 2014-06-06 23:28 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2014-06-06 23:28 UTC (permalink / raw)
To: rickard_strandqvist; +Cc: isdn, netdev, linux-kernel
From: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
Date: Sat, 7 Jun 2014 01:25:30 +0200
> Removes an ifdef that is no longer available,
> and that would cause a compile error if it was activated.
>
> This was partly found using a static code analysis program called cppcheck.
>
> Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
This indentation looks wrong, and if you scan up you'll see why.
A different set of CPP guards create the openning curly brace(s):
/* PROCESS DATA (two members) */
#ifdef CMX_CONF_DEBUG
if (0) {
#else
if (members == 2) {
#endif
This is crazy, and deleting only the DSP_NEVER_DEFINED part makes it
even more confusing because less sophisticated code analysis tools and
editing mode will think that the braces are unbalanced now.
I'm not applying this, it makes things worse not better, sorry.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-06-06 23:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-06 23:25 [PATCH] isdn: mISDN: dsp_cmx.c: Cleaning up a define that is no longer available Rickard Strandqvist
2014-06-06 23:28 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).