lkml.org 
[lkml]   [2002]   [Nov]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] [2.4.20-rc1] compiler fix drivers/ide/pdc202xx.c
Date
Horst von Brand <vonbrand@inf.utfsm.cl> writes:

>"Henning P. Schmiedehausen" <hps@intermeta.de> said:
>> Daniel Mehrmann <daniel.mehrmann@gmx.de> writes:
>>
>> >Hello Marcelo,
>>
>> >i fix a compiler warning from pdc202xx.c.
>> >The "default:" value in the switch was empty. Gcc don`t like
>> >this. We don`t need this one.
>>
>> Correct solution is not to remove the "default:" but to add a "break;"

>So people start wondering if somehow the content of the default case got
>deleted by mistake? Better not. Plus it is needless (source) code bloat.

So comment it:

default:
break; /* Does nothing */

A switch without a default case is simply asking for trouble in the
long run.

Regards
Henning


--
Dipl.-Inf. (Univ.) Henning P. Schmiedehausen -- Geschaeftsfuehrer
INTERMETA - Gesellschaft fuer Mehrwertdienste mbH hps@intermeta.de

Am Schwabachgrund 22 Fon.: 09131 / 50654-0 info@intermeta.de
D-91054 Buckenhof Fax.: 09131 / 50654-20
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:30    [W:0.059 / U:1.312 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site