Mercurial > mplayer.hg
annotate libmpcodecs/ad_mpg123.c @ 34757:da38eb1e2069
subassconvert: handle "\r\n" line ends
Previously the code converting text subtitles to ASS format converted newline
characters, and only those, to ASS "new line" markup. If the subtitles
contained "\r\n", the "\r" was thus left in the text. In previous libass
versions the "\r" was not visible, but in the current one it produces an empty
box. Improve the conversion to remove the "\r" in that case. Also treat a lone
"\r" as a newline.
Picked from mplayer2/3e0a2705
author | cboesch |
---|---|
date | Sat, 07 Apr 2012 11:17:09 +0000 |
parents | 2d928e78d248 |
children | 079b53acda6d |
rev | line source |
---|---|
31524 | 1 /* |
2 * MPEG 1.0/2.0/2.5 audio layer I, II, III decoding with libmpg123 | |
3 * | |
34722 | 4 * Copyright (C) 2010-2012 Thomas Orgis <thomas@orgis.org> |
31524 | 5 * |
6 * MPlayer is free software; you can redistribute it and/or modify | |
7 * it under the terms of the GNU General Public License as published by | |
8 * the Free Software Foundation; either version 2 of the License, or | |
9 * (at your option) any later version. | |
10 * | |
11 * MPlayer is distributed in the hope that it will be useful, | |
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 * GNU General Public License for more details. | |
15 * | |
16 * You should have received a copy of the GNU General Public License along | |
17 * with MPlayer; if not, write to the Free Software Foundation, Inc., | |
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | |
19 */ | |
20 | |
21 #include <stdio.h> | |
22 #include <stdlib.h> | |
23 #include <unistd.h> | |
24 | |
25 #include "config.h" | |
34174
a93891202051
Add missing mp_msg.h #includes, remove some unnecessary ones.
diego
parents:
31981
diff
changeset
|
26 #include "mp_msg.h" |
31524 | 27 #include "ad_internal.h" |
31981
ae5a36acc995
Add the proper include instead of declaring the fakemono variable extern.
diego
parents:
31666
diff
changeset
|
28 #include "dec_audio.h" |
31524 | 29 |
30 static const ad_info_t info = { | |
31 "MPEG 1.0/2.0/2.5 layers I, II, III", | |
32 "mpg123", | |
33 "Thomas Orgis", | |
34 "mpg123.org", | |
35 "High-performance decoder using libmpg123." | |
36 }; | |
37 | |
38 LIBAD_EXTERN(mpg123) | |
39 | |
40 #include "libvo/fastmemcpy.h" | |
41 | |
34722 | 42 /* Reducing the ifdeffery to two main variants: |
43 * 1. most compatible to any libmpg123 version | |
44 * 2. fastest variant with recent libmpg123 (>=1.14) | |
45 * Running variant 2 on older libmpg123 versions may work in | |
46 * principle, but is not supported. | |
47 * So, please leave the check for MPG123_API_VERSION there, m-kay? | |
48 */ | |
31524 | 49 #include <mpg123.h> |
50 | |
34722 | 51 /* Enable faster mode of operation with newer libmpg123, avoiding |
52 * unnecessary memcpy() calls. */ | |
53 #if (defined MPG123_API_VERSION) && (MPG123_API_VERSION >= 33) | |
54 #define AD_MPG123_FRAMEWISE | |
55 #endif | |
31524 | 56 |
57 /* Switch for updating bitrate info of VBR files. Not essential. */ | |
58 #define AD_MPG123_MEAN_BITRATE | |
59 | |
60 struct ad_mpg123_context { | |
61 mpg123_handle *handle; | |
62 #ifdef AD_MPG123_MEAN_BITRATE | |
63 /* Running mean for bit rate, stream length estimation. */ | |
64 float mean_rate; | |
65 unsigned int mean_count; | |
66 /* Time delay for updates. */ | |
67 short delay; | |
68 #endif | |
69 /* If the stream is actually VBR. */ | |
70 char vbr; | |
71 }; | |
72 | |
73 /* This initializes libmpg123 and prepares the handle, including funky | |
74 * parameters. */ | |
75 static int preinit(sh_audio_t *sh) | |
76 { | |
77 int err, flag; | |
78 struct ad_mpg123_context *con; | |
79 /* Assumption: You always call preinit + init + uninit, on every file. | |
80 * But you stop at preinit in case it fails. | |
81 * If that is not true, one must ensure not to call mpg123_init / exit | |
82 * twice in a row. */ | |
83 if (mpg123_init() != MPG123_OK) | |
84 return 0; | |
85 | |
86 sh->context = malloc(sizeof(struct ad_mpg123_context)); | |
87 con = sh->context; | |
88 /* Auto-choice of optimized decoder (first argument NULL). */ | |
89 con->handle = mpg123_new(NULL, &err); | |
90 if (!con->handle) | |
91 goto bad_end; | |
92 | |
93 #ifdef CONFIG_FAKE_MONO | |
94 /* Guessing here: Default value triggers forced upmix of mono to stereo. */ | |
95 flag = fakemono == 0 ? MPG123_FORCE_STEREO : | |
96 fakemono == 1 ? MPG123_MONO_LEFT : | |
97 fakemono == 2 ? MPG123_MONO_RIGHT : 0; | |
98 if (mpg123_param(con->handle, MPG123_ADD_FLAGS, flag, 0.0) != MPG123_OK) | |
99 goto bad_end; | |
100 #endif | |
101 | |
102 /* Basic settings. | |
103 * Don't spill messages, enable better resync with non-seekable streams. | |
104 * Give both flags individually without error checking to keep going with | |
105 * old libmpg123. Generally, it is not fatal if the flags are not | |
106 * honored */ | |
107 mpg123_param(con->handle, MPG123_ADD_FLAGS, MPG123_QUIET, 0.0); | |
31666 | 108 /* Do not bail out on malformed streams at all. |
109 * MPlayer does not handle a decoder throwing the towel on crappy input. */ | |
110 mpg123_param(con->handle, MPG123_RESYNC_LIMIT, -1, 0.0); | |
31524 | 111 |
112 /* Open decisions: Configure libmpg123 to force encoding (or stay open about | |
113 * library builds that support only float or int32 output), (de)configure | |
114 * gapless decoding (won't work with seeking in MPlayer, though). | |
115 * Don't forget to eventually enable ReplayGain/RVA support, too. | |
116 * Let's try to run with the default for now. */ | |
117 | |
34722 | 118 /* That would produce floating point output. |
119 * You can get 32 and 24 bit ints, even 8 bit via format matrix. */ | |
120 /* mpg123_param(con->handle, MPG123_ADD_FLAGS, MPG123_FORCE_FLOAT, 0.); */ | |
121 | |
31524 | 122 /* Example for RVA choice (available since libmpg123 1.0.0): |
123 mpg123_param(con->handle, MPG123_RVA, MPG123_RVA_MIX, 0.0) */ | |
124 | |
34722 | 125 #ifdef AD_MPG123_FRAMEWISE |
126 /* Prevent funky automatic resampling. | |
127 * This way, we can be sure that one frame will never produce | |
128 * more than 1152 stereo samples. */ | |
129 mpg123_param(con->handle, MPG123_REMOVE_FLAGS, MPG123_AUTO_RESAMPLE, 0.); | |
130 #else | |
131 /* Older mpg123 is vulnerable to concatenated streams when gapless cutting | |
132 * is enabled (will only play the jingle of a badly constructed radio | |
133 * stream). The versions using framewise decoding are fine with that. */ | |
134 mpg123_param(con->handle, MPG123_REMOVE_FLAGS, MPG123_GAPLESS, 0.); | |
135 #endif | |
136 | |
31524 | 137 return 1; |
138 | |
139 bad_end: | |
140 if (!con->handle) | |
141 mp_msg(MSGT_DECAUDIO, MSGL_ERR, "mpg123 preinit error: %s\n", | |
142 mpg123_plain_strerror(err)); | |
143 else | |
144 mp_msg(MSGT_DECAUDIO, MSGL_ERR, "mpg123 preinit error: %s\n", | |
145 mpg123_strerror(con->handle)); | |
146 | |
147 if (con->handle) | |
148 mpg123_delete(con->handle); | |
149 mpg123_exit(); | |
150 free(sh->context); | |
151 sh->context = NULL; | |
152 return 0; | |
153 } | |
154 | |
155 /* Compute bitrate from frame size. */ | |
156 static int compute_bitrate(struct mpg123_frameinfo *i) | |
157 { | |
158 static const int samples_per_frame[4][4] = { | |
159 {-1, 384, 1152, 1152}, /* MPEG 1 */ | |
160 {-1, 384, 1152, 576}, /* MPEG 2 */ | |
161 {-1, 384, 1152, 576}, /* MPEG 2.5 */ | |
162 {-1, -1, -1, -1}, /* Unknown */ | |
163 }; | |
164 return (int) ((i->framesize + 4) * 8 * i->rate * 0.001 / | |
165 samples_per_frame[i->version][i->layer] + 0.5); | |
166 } | |
167 | |
168 /* Opted against the header printout from old mp3lib, too much | |
169 * irrelevant info. This is modelled after the mpg123 app's | |
170 * standard output line. | |
171 * If more verbosity is demanded, one can add more detail and | |
172 * also throw in ID3v2 info which libmpg123 collects anyway. */ | |
173 static void print_header_compact(struct mpg123_frameinfo *i) | |
174 { | |
175 static const char *smodes[5] = { | |
176 "stereo", "joint-stereo", "dual-channel", "mono", "invalid" | |
177 }; | |
178 static const char *layers[4] = { | |
179 "Unknown", "I", "II", "III" | |
180 }; | |
181 static const char *versions[4] = { | |
182 "1.0", "2.0", "2.5", "x.x" | |
183 }; | |
184 | |
185 mp_msg(MSGT_DECAUDIO, MSGL_V, "MPEG %s layer %s, ", | |
186 versions[i->version], layers[i->layer]); | |
187 switch (i->vbr) { | |
188 case MPG123_CBR: | |
189 if (i->bitrate) | |
190 mp_msg(MSGT_DECAUDIO, MSGL_V, "%d kbit/s", i->bitrate); | |
191 else | |
192 mp_msg(MSGT_DECAUDIO, MSGL_V, "%d kbit/s (free format)", | |
193 compute_bitrate(i)); | |
194 break; | |
195 case MPG123_VBR: | |
196 mp_msg(MSGT_DECAUDIO, MSGL_V, "VBR"); | |
197 break; | |
198 case MPG123_ABR: | |
199 mp_msg(MSGT_DECAUDIO, MSGL_V, "%d kbit/s ABR", i->abr_rate); | |
200 break; | |
201 default: | |
202 mp_msg(MSGT_DECAUDIO, MSGL_V, "???"); | |
203 } | |
204 mp_msg(MSGT_DECAUDIO, MSGL_V, ", %ld Hz %s\n", i->rate, | |
205 smodes[i->mode]); | |
206 } | |
207 | |
34722 | 208 /* return MPG123_OK if decoder is ready to produce output |
209 * the other usual return code would be MPG123_NEED_MORE. */ | |
210 static int have_initial_frame(mpg123_handle *mh) | |
211 { | |
212 long rate; | |
213 int chan, enc; | |
214 /* Abusing the format query function. | |
215 * It returns MPG123_OK if an intial frame has been parsed. | |
216 * It returns MPG123_NEED_MORE if input data is needed. | |
217 * Not handing NULL pointers for compatibility with old libmpg123. */ | |
218 return mpg123_getformat(mh, &rate, &chan, &enc); | |
219 } | |
220 | |
31524 | 221 /* This tries to extract a requested amount of decoded data. |
222 * Even when you request 0 bytes, it will feed enough input so that | |
223 * the decoder _could_ have delivered something. | |
224 * Returns byte count >= 0, -1 on error. | |
225 * | |
226 * Thoughts on exact pts keeping: | |
227 * We have to assume that MPEG frames are cut in pieces by packet boundaries. | |
228 * Also, it might be possible that the first packet does not contain enough | |
229 * data to ensure initial stream sync... or re-sync on erroneous streams. | |
230 * So we need something robust to relate the decoded byte count to the correct | |
231 * time stamp. This is tricky, though. From the outside, you cannot tell if, | |
232 * after having fed two packets until the first output arrives, one should | |
233 * start counting from the first packet's pts or the second packet's. | |
234 * So, let's just count from the last fed package's pts. If the packets are | |
235 * exactly cut to MPEG frames, this will cause one frame mismatch in the | |
236 * beginning (when mpg123 peeks ahead for the following header), but will | |
237 * be corrected with the third frame already. One might add special code to | |
238 * not increment the base pts past the first packet's after a resync before | |
239 * the first decoded bytes arrived. */ | |
240 static int decode_a_bit(sh_audio_t *sh, unsigned char *buf, int count) | |
241 { | |
242 int ret = MPG123_OK; | |
243 int got = 0; | |
244 struct ad_mpg123_context *con = sh->context; | |
245 | |
246 /* There will be one MPG123_NEW_FORMAT message on first open. | |
34722 | 247 * This will be handled in init(). */ |
31524 | 248 do { |
249 size_t got_now = 0; | |
250 | |
34722 | 251 /* Feed the decoder. This will only fire from the second round on. */ |
31524 | 252 if (ret == MPG123_NEED_MORE) { |
253 int incount; | |
254 double pts; | |
255 unsigned char *inbuf; | |
256 /* Feed more input data. */ | |
257 incount = ds_get_packet_pts(sh->ds, &inbuf, &pts); | |
258 if (incount <= 0) | |
259 break; /* Apparently that's it. EOF. */ | |
260 | |
261 /* Next bytes from that presentation time. */ | |
262 if (pts != MP_NOPTS_VALUE) { | |
263 sh->pts = pts; | |
264 sh->pts_bytes = 0; | |
265 } | |
34722 | 266 |
267 #ifdef AD_MPG123_FRAMEWISE | |
268 /* Have to use mpg123_feed() to avoid decoding here. */ | |
269 ret = mpg123_feed(con->handle, inbuf, incount); | |
31524 | 270 #else |
271 /* Do not use mpg123_feed(), added in later libmpg123 versions. */ | |
272 ret = mpg123_decode(con->handle, inbuf, incount, NULL, 0, NULL); | |
34722 | 273 #endif |
274 if (ret == MPG123_ERR) | |
275 break; | |
31524 | 276 } |
34722 | 277 /* Theoretically, mpg123 could return MPG123_DONE, so be prepared. |
278 * Should not happen in our usage, but it is a valid return code. */ | |
31524 | 279 else if (ret == MPG123_ERR || ret == MPG123_DONE) |
280 break; | |
281 | |
34722 | 282 /* Try to decode a bit. This is the return value that counts |
283 * for the loop condition. */ | |
284 #ifdef AD_MPG123_FRAMEWISE | |
285 if (!buf) { /* fake call just for feeding to get format */ | |
286 ret = have_initial_frame(con->handle); | |
287 } else { /* This is the decoding. One frame at a time. */ | |
288 ret = mpg123_replace_buffer(con->handle, buf, count); | |
289 if (ret == MPG123_OK) | |
290 ret = mpg123_decode_frame(con->handle, NULL, NULL, &got_now); | |
291 } | |
292 #else | |
293 ret = mpg123_decode(con->handle, NULL, 0, buf + got, count - got, | |
294 &got_now); | |
295 #endif | |
296 | |
297 got += got_now; | |
298 sh->pts_bytes += got_now; | |
299 | |
300 #ifdef AD_MPG123_FRAMEWISE | |
301 } while (ret == MPG123_NEED_MORE || (got == 0 && count != 0)); | |
302 #else | |
31524 | 303 } while (ret == MPG123_NEED_MORE || got < count); |
34722 | 304 #endif |
31524 | 305 |
306 if (ret == MPG123_ERR) { | |
307 mp_msg(MSGT_DECAUDIO, MSGL_ERR, "mpg123 decoding failed: %s\n", | |
308 mpg123_strerror(con->handle)); | |
309 mpg123_close(con->handle); | |
310 return -1; | |
311 } | |
312 | |
313 return got; | |
314 } | |
315 | |
316 /* Close, reopen stream. Feed data until we know the format of the stream. | |
317 * 1 on success, 0 on error */ | |
318 static int reopen_stream(sh_audio_t *sh) | |
319 { | |
320 struct ad_mpg123_context *con = (struct ad_mpg123_context*) sh->context; | |
321 | |
322 mpg123_close(con->handle); | |
34722 | 323 /* No resetting of the context: |
324 * We do not want to loose the mean bitrate data. */ | |
31524 | 325 |
34722 | 326 /* Open and make sure we have fed enough data to get stream properties. */ |
327 if (MPG123_OK == mpg123_open_feed(con->handle) && | |
31524 | 328 /* Feed data until mpg123 is ready (has found stream beginning). */ |
329 !decode_a_bit(sh, NULL, 0) && | |
34722 | 330 MPG123_OK == have_initial_frame(con->handle)) { |
31524 | 331 return 1; |
332 } else { | |
333 mp_msg(MSGT_DECAUDIO, MSGL_ERR, | |
334 "mpg123 failed to reopen stream: %s\n", | |
335 mpg123_strerror(con->handle)); | |
336 mpg123_close(con->handle); | |
337 return 0; | |
338 } | |
339 } | |
340 | |
341 /* Now we really start accessing some data and determining file format. | |
342 * Paranoia note: The mpg123_close() on errors is not really necessary, | |
343 * But it ensures that we don't accidentally continue decoding with a | |
344 * bad state (possibly interpreting the format badly or whatnot). */ | |
345 static int init(sh_audio_t *sh) | |
346 { | |
347 long rate = 0; | |
348 int channels = 0; | |
349 int encoding = 0; | |
350 mpg123_id3v2 *v2; | |
351 struct mpg123_frameinfo finfo; | |
352 struct ad_mpg123_context *con = sh->context; | |
353 | |
354 /* We're open about any output format that libmpg123 will suggest. | |
355 * Note that a standard build will always default to 16 bit signed and | |
356 * the native sample rate of the file. */ | |
357 if (MPG123_OK == mpg123_format_all(con->handle) && | |
358 reopen_stream(sh) && | |
359 MPG123_OK == mpg123_getformat(con->handle, &rate, &channels, &encoding) && | |
360 /* Forbid the format to change later on. */ | |
361 MPG123_OK == mpg123_format_none(con->handle) && | |
362 MPG123_OK == mpg123_format(con->handle, rate, channels, encoding) && | |
363 /* Get MPEG header info. */ | |
364 MPG123_OK == mpg123_info(con->handle, &finfo) && | |
365 /* Since we queried format, mpg123 should have read past ID3v2 tags. | |
366 * We need to decide if printing of UTF-8 encoded text info is wanted. */ | |
367 MPG123_OK == mpg123_id3(con->handle, NULL, &v2)) { | |
368 /* If we are here, we passed all hurdles. Yay! Extract the info. */ | |
369 print_header_compact(&finfo); | |
370 /* Do we want to print out the UTF-8 Id3v2 info? | |
371 if (v2) | |
372 print_id3v2(v2); */ | |
373 | |
374 /* Have kb/s, want B/s | |
375 * For VBR, the first frame will be a bad estimate. */ | |
376 sh->i_bps = (finfo.bitrate ? finfo.bitrate : compute_bitrate(&finfo)) | |
377 * 1000 / 8; | |
34722 | 378 #ifdef AD_MPG123_MEAN_BITRATE |
379 con->delay = 1; | |
380 con->mean_rate = 0.; | |
381 con->mean_count = 0; | |
382 #endif | |
31524 | 383 con->vbr = (finfo.vbr != MPG123_CBR); |
384 sh->channels = channels; | |
385 sh->samplerate = rate; | |
386 /* Without external force, mpg123 will always choose signed encoding, | |
387 * and non-16-bit only on builds that don't support it. | |
388 * Be reminded that it doesn't matter to the MPEG file what encoding | |
389 * is produced from it. */ | |
390 switch (encoding) { | |
391 case MPG123_ENC_SIGNED_8: | |
392 sh->sample_format = AF_FORMAT_S8; | |
393 sh->samplesize = 1; | |
394 break; | |
395 case MPG123_ENC_SIGNED_16: | |
396 sh->sample_format = AF_FORMAT_S16_NE; | |
397 sh->samplesize = 2; | |
398 break; | |
399 /* To stay compatible with the oldest libmpg123 headers, do not rely | |
400 * on float and 32 bit encoding symbols being defined. | |
401 * Those formats came later */ | |
402 case 0x1180: /* MPG123_ENC_SIGNED_32 */ | |
403 sh->sample_format = AF_FORMAT_S32_NE; | |
404 sh->samplesize = 4; | |
405 break; | |
406 case 0x200: /* MPG123_ENC_FLOAT_32 */ | |
407 sh->sample_format = AF_FORMAT_FLOAT_NE; | |
408 sh->samplesize = 4; | |
409 break; | |
410 default: | |
411 mp_msg(MSGT_DECAUDIO, MSGL_ERR, | |
412 "Bad encoding from mpg123: %i.\n", encoding); | |
413 mpg123_close(con->handle); | |
414 return 0; | |
415 } | |
34722 | 416 #ifdef AD_MPG123_FRAMEWISE |
417 /* Going to decode directly to MPlayer's memory. It is important | |
418 * to have MPG123_AUTO_RESAMPLE disabled for the buffer size | |
419 * being an all-time limit. */ | |
420 sh->audio_out_minsize = 1152 * 2 * sh->samplesize; | |
421 #endif | |
31524 | 422 |
423 return 1; | |
424 } else { | |
425 mp_msg(MSGT_DECAUDIO, MSGL_ERR, "mpg123 init error: %s\n", | |
426 mpg123_strerror(con->handle)); | |
427 mpg123_close(con->handle); | |
428 return 0; | |
429 } | |
430 } | |
431 | |
432 static void uninit(sh_audio_t *sh) | |
433 { | |
434 struct ad_mpg123_context *con = (struct ad_mpg123_context*) sh->context; | |
435 | |
436 mpg123_close(con->handle); | |
437 mpg123_delete(con->handle); | |
438 free(sh->context); | |
439 sh->context = NULL; | |
440 mpg123_exit(); | |
441 } | |
442 | |
443 #ifdef AD_MPG123_MEAN_BITRATE | |
444 /* Update mean bitrate. This could be dropped if accurate time display | |
445 * on audio file playback is not desired. */ | |
446 static void update_info(sh_audio_t *sh) | |
447 { | |
448 struct ad_mpg123_context *con = sh->context; | |
449 if (con->vbr && --con->delay < 1) { | |
450 struct mpg123_frameinfo finfo; | |
451 if (MPG123_OK == mpg123_info(con->handle, &finfo)) { | |
452 if (++con->mean_count > ((unsigned int) -1) / 2) | |
453 con->mean_count = ((unsigned int) -1) / 4; | |
454 | |
455 /* Might not be numerically optimal, but works fine enough. */ | |
456 con->mean_rate = ((con->mean_count - 1) * con->mean_rate + | |
457 finfo.bitrate) / con->mean_count; | |
458 sh->i_bps = (int) (con->mean_rate * 1000 / 8); | |
459 | |
460 con->delay = 10; | |
461 } | |
462 } | |
463 } | |
464 #endif | |
465 | |
466 static int decode_audio(sh_audio_t *sh, unsigned char *buf, int minlen, | |
467 int maxlen) | |
468 { | |
469 int bytes; | |
470 | |
34722 | 471 bytes = decode_a_bit(sh, buf, maxlen); |
31524 | 472 if (bytes == 0) |
473 return -1; /* EOF */ | |
474 | |
475 #ifdef AD_MPG123_MEAN_BITRATE | |
476 update_info(sh); | |
477 #endif | |
478 return bytes; | |
479 } | |
480 | |
481 static int control(sh_audio_t *sh, int cmd, void *arg, ...) | |
482 { | |
483 switch (cmd) { | |
484 case ADCTRL_RESYNC_STREAM: | |
485 /* Close/reopen the stream for mpg123 to make sure it doesn't | |
486 * think that it still knows the exact stream position. | |
487 * Otherwise, we would have funny effects from the gapless code. | |
488 * Oh, and it helps to minimize artifacts from jumping in the stream. */ | |
489 if (reopen_stream(sh)) { | |
490 #ifdef AD_MPG123_MEAN_BITRATE | |
491 update_info(sh); | |
492 #endif | |
493 return CONTROL_TRUE; | |
494 } else { | |
495 mp_msg(MSGT_DECAUDIO, MSGL_ERR, | |
496 "mpg123 cannot reopen stream for resync.\n"); | |
497 return CONTROL_FALSE; | |
498 } | |
499 break; | |
500 } | |
501 return CONTROL_UNKNOWN; | |
502 } |