1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
Index: apps/recorder/bmp.c
===================================================================
--- apps/recorder/bmp.c  (revision 29804)
+++ apps/recorder/bmp.c  (working copy)
@@ -492,7 +492,6 @@
 #if (LCD_DEPTH > 1 || (defined(HAVE_REMOTE_LCD) && LCD_REMOTE_DEPTH > 1)) && \
     defined(HAVE_BMP_SCALING) || defined(PLUGIN)
     unsigned int resize = IMG_NORESIZE;
-    bool transparent = false;
 
 #ifdef HAVE_REMOTE_LCD
     bool remote = false;
@@ -508,9 +507,6 @@
         resize = IMG_RESIZE;
     }
 
-    if (format & FORMAT_TRANSPARENT) {
-        transparent = true;
-    }
 #else
 
     (void)format;
Index: apps/plugins/pictureflow/pictureflow.c
===================================================================
--- apps/plugins/pictureflow/pictureflow.c  (revision 29804)
+++ apps/plugins/pictureflow/pictureflow.c  (working copy)
@@ -1257,14 +1257,13 @@
 {
     if ( force || ! rb->file_exists( EMPTY_SLIDE ) )  {
         struct bitmap input_bmp;
-        int ret;
         input_bmp.width = DISPLAY_WIDTH;
         input_bmp.height = DISPLAY_HEIGHT;
 #if LCD_DEPTH > 1
         input_bmp.format = FORMAT_NATIVE;
 #endif
         input_bmp.data = (char*)buf;
-        ret = scaled_read_bmp_file(EMPTY_SLIDE_BMP, &input_bmp,
+        scaled_read_bmp_file(EMPTY_SLIDE_BMP, &input_bmp,
                                 buf_size,
                                 FORMAT_NATIVE|FORMAT_RESIZE|FORMAT_KEEP_ASPECT,
                                 &format_transposed);
Index: apps/gui/quickscreen.c
===================================================================
--- apps/gui/quickscreen.c  (revision 29804)
+++ apps/gui/quickscreen.c  (working copy)
@@ -171,7 +171,6 @@
     int i;
     char buf[MAX_PATH];
     unsigned const char *title, *value;
-    void *setting;
     int temp;
     display->set_viewport(parent);
     display->clear_viewport();
@@ -184,7 +183,6 @@
         display->set_viewport(vp);
 
         title = P2STR(ID2P(qs->items[i]->lang_id));
-        setting = qs->items[i]->setting;
         temp = option_value_as_int(qs->items[i]);
         value = option_get_valuestring(qs->items[i],
                                        buf, MAX_PATH, temp);
Index: apps/codecs/aiff.c
===================================================================
--- apps/codecs/aiff.c  (revision 29804)
+++ apps/codecs/aiff.c  (working copy)
@@ -77,7 +77,9 @@
 {
     struct pcm_format format;
     uint32_t bytesdone, decodedsamples;
+    /* rockbox: comment 'set but unused' variables
     uint32_t num_sample_frames = 0;
+    */
     size_t n;
     int bufcount;
     int endofstream;
@@ -146,8 +148,11 @@
             /* num_channels */
             format.channels = ((buf[8]<<8)|buf[9]);
             /* num_sample_frames */
+            /*
             num_sample_frames = ((buf[10]<<24)|(buf[11]<<16)|(buf[12]<<8)
                                 |buf[13]);
+            */
+            
             /* sample_size */
             format.bitspersample = ((buf[14]<<8)|buf[15]);
             /* sample_rate (don't use last 4 bytes, only integer fs) */
Index: apps/codecs/libasf/asf.c
===================================================================
--- apps/codecs/libasf/asf.c  (revision 29804)
+++ apps/codecs/libasf/asf.c  (working copy)
@@ -59,16 +59,18 @@
     uint8_t* datap;
     uint32_t length;
     uint32_t padding_length;
+    /* rockbox: comment 'set but unused' variables
     uint32_t send_time;
     uint16_t duration;
+    uint32_t media_object_number;
+    uint32_t media_object_offset;
+    */
     uint16_t payload_count;
     int payload_length_type;
     uint32_t payload_hdrlen;
     int payload_datalen;
     int multiple;
     uint32_t replicated_length;
-    uint32_t media_object_number;
-    uint32_t media_object_offset;
     uint32_t bytesread = 0;
     uint8_t* buf;
     size_t bufsize;
@@ -133,9 +135,9 @@
     datap += GETLEN2b((packet_flags >> 1) & 0x03);
     padding_length = GETVALUE2b((packet_flags >> 3) & 0x03, datap);
     datap += GETLEN2b((packet_flags >> 3) & 0x03);
-    send_time = get_long_le(datap);
+    /* send_time = get_long_le(datap); */
     datap += 4;
-    duration = get_short_le(datap);
+    /* duration = get_short_le(datap); */
     datap += 2;
     /*DEBUGF("and duration %d ms\n", duration);*/
 
@@ -225,9 +227,9 @@
         }
 
         bytesread += payload_hdrlen;
-        media_object_number = GETVALUE2b((packet_property >> 4) & 0x03, datap);
+        /* media_object_number = GETVALUE2b((packet_property >> 4) & 0x03, datap); */
         datap += GETLEN2b((packet_property >> 4) & 0x03);
-        media_object_offset = GETVALUE2b((packet_property >> 2) & 0x03, datap);
+        /* media_object_offset = GETVALUE2b((packet_property >> 2) & 0x03, datap); */
         datap += GETLEN2b((packet_property >> 2) & 0x03);
         replicated_length = GETVALUE2b(packet_property & 0x03, datap);
         datap += GETLEN2b(packet_property & 0x03);
@@ -299,8 +301,10 @@
     int datalen;
     uint8_t data[18];
     uint8_t* datap;
+    /* rockbox: comment 'set but unused' variables
     uint32_t length;
     uint32_t padding_length;
+    */
     uint32_t send_time;
     static int packet_count = 0;
 
@@ -359,13 +363,13 @@
     bytesread += datalen;
 
     datap = data;
-    length = GETVALUE2b((packet_flags >> 5) & 0x03, datap);
+    /* length = GETVALUE2b((packet_flags >> 5) & 0x03, datap); */
     datap += GETLEN2b((packet_flags >> 5) & 0x03);
 
     /* sequence value is not used */
     GETVALUE2b((packet_flags >> 1) & 0x03, datap);
     datap += GETLEN2b((packet_flags >> 1) & 0x03);
-    padding_length = GETVALUE2b((packet_flags >> 3) & 0x03, datap);
+    /* padding_length = GETVALUE2b((packet_flags >> 3) & 0x03, datap); */
     datap += GETLEN2b((packet_flags >> 3) & 0x03);
     send_time = get_long_le(datap);
     datap += 4;
Index: apps/codecs/speex.c
===================================================================
--- apps/codecs/speex.c  (revision 29804)
+++ apps/codecs/speex.c  (working copy)
@@ -396,7 +396,9 @@
     int samplerate = ci->id3->frequency;
     int extra_headers = 0;
     int stream_init = 0;
+    /* rockbox: comment 'set but unused' variables
     int page_nb_packets;
+    */
     int frame_size;
     int packet_count = 0;
     int lookahead;
@@ -465,7 +467,7 @@
             spx_ogg_stream_pagein(&os, &og);
 
             page_granule = spx_ogg_page_granulepos(&og);
-            page_nb_packets = spx_ogg_page_packets(&og);
+            /* page_nb_packets = spx_ogg_page_packets(&og); */
 
             cur_granule = page_granule;
 
Index: apps/codecs/libwma/wmadeci.c
===================================================================
--- apps/codecs/libwma/wmadeci.c  (revision 29804)
+++ apps/codecs/libwma/wmadeci.c  (working copy)
@@ -598,7 +598,7 @@
 static void wma_lsp_to_curve_init(WMADecodeContext *s, int frame_len)
 {
     fixed32 wdel, a, b, temp2;
-    int i, m;
+    int i;
 
     wdel = fixdiv32(itofix32(1),     itofix32(frame_len));
     for (i=0; i<frame_len; ++i)
@@ -620,7 +620,6 @@
     /*double check this later*/
     for(i=(1 << LSP_POW_BITS) - 1;i>=0;i--)
     {
-        m = (1 << LSP_POW_BITS) + i;
         a = pow_a_table[ix++]<<4;
         ((fixed32*)s->lsp_pow_m_table1)[i] = 2 * a - b;
         ((fixed32*)s->lsp_pow_m_table2)[i] = b - a;
Index: apps/codecs/wmapro.c
===================================================================
--- apps/codecs/wmapro.c  (revision 29804)
+++ apps/codecs/wmapro.c  (working copy)
@@ -44,7 +44,6 @@
 {
     uint32_t elapsedtime;
     asf_waveformatex_t wfx;     /* Holds the stream properties */
-    size_t resume_offset;
     int res;                    /* Return values from asf_read_packet() and decode_packet() */
     uint8_t* audiobuf;          /* Pointer to the payload of one wma pro packet */
     int audiobufsize;           /* Payload size */
@@ -55,9 +54,6 @@
     int size;                   /* Size of the input frame to the decoder */
     intptr_t param;
 
-    /* Remember the resume position */
-    resume_offset = ci->id3->offset;
-
 restart_track:
     if (codec_init()) {
         LOGF("(WMA PRO) Error: Error initialising codec\n");
@@ -82,12 +78,11 @@
     ci->seek_buffer(ci->id3->first_frame_offset);
     
     elapsedtime = 0;
-    resume_offset = 0;
     
     /* The main decoding loop */
 
     while (pktcnt < wfx.numpackets)
-    {
+    { 
         enum codec_command_action action = ci->get_command(&param);
 
         if (action == CODEC_ACTION_HALT)
Index: apps/codecs/sid.c
===================================================================
--- apps/codecs/sid.c  (revision 29804)
+++ apps/codecs/sid.c  (working copy)
@@ -270,7 +270,6 @@
 
 static inline int GenerateDigi(int sIn)
 {
-    static int last_sample = 0;
     static int sample = 0;
 
     if (!sample_active) return(sIn);
@@ -283,9 +282,7 @@
         
         if (fracPos > mixing_frequency) 
         {
-            fracPos%=mixing_frequency;
-
-            last_sample = sample;           
+            fracPos%=mixing_frequency;        
                         
             // N�hstes Samples holen
             if (sample_order == 0) {
Index: apps/codecs/libspeex/nb_celp.c
===================================================================
--- apps/codecs/libspeex/nb_celp.c  (revision 29804)
+++ apps/codecs/libspeex/nb_celp.c  (working copy)
@@ -1001,12 +1001,13 @@
 }
 
 void nb_decoder_destroy(void *state)
-{
+{   
+#if !(defined(VAR_ARRAYS) || defined (USE_ALLOCA))
    DecState *st;
    st=(DecState*)state;
-   
-#if !(defined(VAR_ARRAYS) || defined (USE_ALLOCA))
    speex_free_scratch(st->stack);
+#else
+    (void)state;
 #endif
 /*
    speex_free (st->excBuf);
@@ -1315,7 +1316,6 @@
    {
       int offset;
       spx_word16_t *exc;
-      spx_word16_t *sp;
       spx_word16_t *innov_save = NULL;
       spx_word16_t tmp;
 
@@ -1323,8 +1323,7 @@
       offset = st->subframeSize*sub;
       /* Excitation */
       exc=st->exc+offset;
-      /* Original signal */
-      sp=out+offset;
+
       if (st->innov_save)
          innov_save = st->innov_save+offset;
 
@@ -1517,13 +1516,11 @@
    {
       int offset;
       spx_word16_t *sp;
-      spx_word16_t *exc;
+
       /* Offset relative to start of frame */
       offset = st->subframeSize*sub;
       /* Original signal */
       sp=out+offset;
-      /* Excitation */
-      exc=st->exc+offset;
 
       /* LSP interpolation (quantized and unquantized) */
       lsp_interpolate(st->old_qlsp, qlsp, interp_qlsp, st->lpcSize, sub, st->nbSubframes);
Index: apps/codecs/libspeex/cb_search.c
===================================================================
--- apps/codecs/libspeex/cb_search.c  (revision 29804)
+++ apps/codecs/libspeex/cb_search.c  (working copy)
@@ -529,14 +529,13 @@
    VARDECL(int *ind);
    VARDECL(int *signs);
    const signed char *shape_cb;
-   int shape_cb_size, subvect_size, nb_subvect;
+   int subvect_size, nb_subvect;
    const split_cb_params *params;
    int have_sign;
 
    params = (const split_cb_params *) par;
    subvect_size = params->subvect_size;
    nb_subvect = params->nb_subvect;
-   shape_cb_size = 1<<params->shape_bits;
    shape_cb = params->shape_cb;
    have_sign = params->have_sign;