Mercurial > hg > nginx
comparison src/http/modules/ngx_http_range_filter.c @ 356:2e3cbc1bbe3c
nginx-0.0.7-2004-06-16-19:32:11 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Wed, 16 Jun 2004 15:32:11 +0000 |
parents | 55e496a8ece3 |
children | 3c56e834be46 |
comparison
equal
deleted
inserted
replaced
355:0fb6c53fb135 | 356:2e3cbc1bbe3c |
---|---|
337 */ | 337 */ |
338 | 338 |
339 if (r->headers_out.charset.len) { | 339 if (r->headers_out.charset.len) { |
340 ctx->boundary_header.len = | 340 ctx->boundary_header.len = |
341 ngx_snprintf((char *) ctx->boundary_header.data, len, | 341 ngx_snprintf((char *) ctx->boundary_header.data, len, |
342 CRLF "--%010u" CRLF | 342 CRLF "--%010" NGX_UINT_T_FMT CRLF |
343 "Content-Type: %s; charset=%s" CRLF | 343 "Content-Type: %s; charset=%s" CRLF |
344 "Content-Range: bytes ", | 344 "Content-Range: bytes ", |
345 boundary, | 345 boundary, |
346 r->headers_out.content_type->value.data, | 346 r->headers_out.content_type->value.data, |
347 r->headers_out.charset.data); | 347 r->headers_out.charset.data); |
349 r->headers_out.charset.len = 0; | 349 r->headers_out.charset.len = 0; |
350 | 350 |
351 } else { | 351 } else { |
352 ctx->boundary_header.len = | 352 ctx->boundary_header.len = |
353 ngx_snprintf((char *) ctx->boundary_header.data, len, | 353 ngx_snprintf((char *) ctx->boundary_header.data, len, |
354 CRLF "--%010u" CRLF | 354 CRLF "--%010" NGX_UINT_T_FMT CRLF |
355 "Content-Type: %s" CRLF | 355 "Content-Type: %s" CRLF |
356 "Content-Range: bytes ", | 356 "Content-Range: bytes ", |
357 boundary, | 357 boundary, |
358 r->headers_out.content_type->value.data); | 358 r->headers_out.content_type->value.data); |
359 } | 359 } |
366 | 366 |
367 r->headers_out.content_type->value.len = | 367 r->headers_out.content_type->value.len = |
368 ngx_snprintf((char *) | 368 ngx_snprintf((char *) |
369 r->headers_out.content_type->value.data, | 369 r->headers_out.content_type->value.data, |
370 31 + 10 + 1, | 370 31 + 10 + 1, |
371 "multipart/byteranges; boundary=%010u", | 371 "multipart/byteranges; boundary=%010" |
372 NGX_UINT_T_FMT, | |
372 boundary); | 373 boundary); |
373 | 374 |
374 /* the size of the last boundary CRLF "--0123456789--" CRLF */ | 375 /* the size of the last boundary CRLF "--0123456789--" CRLF */ |
375 len = 4 + 10 + 4; | 376 len = 4 + 10 + 4; |
376 | 377 |