Skip to content

Commit

Permalink
audio_stream/http_stream: fix code format
Browse files Browse the repository at this point in the history
Just opening this file with vim configured with editorconfig and then
saving it causes these changes.

Signed-off-by: Stijn Tintel <[email protected]>
  • Loading branch information
stintel committed Sep 27, 2023
1 parent 5d76d8c commit aea0890
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions components/audio_stream/http_stream.c
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ static esp_err_t _resolve_playlist(audio_element_handle_t self, const char *uri)
if (http->hls_key->key_url == NULL) {
ESP_LOGE(TAG, "No memory for hls key url");
return ESP_FAIL;
}
}
}
http->hls_key->sequence_no = hls_playlist_get_sequence_no(hls);
}
Expand Down Expand Up @@ -569,7 +569,7 @@ static esp_err_t _http_open(audio_element_handle_t self)
ESP_LOGE(TAG, "Error open connection, uri = NULL");
return ESP_FAIL;
}

ESP_LOGD(TAG, "URI=%s", uri);
// if not initialize http client, initial it
if (http->client == NULL) {
Expand Down Expand Up @@ -743,8 +743,8 @@ static int _http_read(audio_element_handle_t self, char *buffer, int len, TickTy
return ESP_OK;
} else {
if (http->hls_key) {
int ret = esp_aes_crypt_cbc(&http->hls_key->aes_ctx, ESP_AES_DECRYPT,
rlen, (unsigned char*)http->hls_key->key.iv,
int ret = esp_aes_crypt_cbc(&http->hls_key->aes_ctx, ESP_AES_DECRYPT,
rlen, (unsigned char*)http->hls_key->key.iv,
(unsigned char*)buffer, (unsigned char*)buffer);
if (rlen % 16 != 0) {
ESP_LOGE(TAG, "Data length %d not aligned", rlen);
Expand Down
2 changes: 1 addition & 1 deletion components/audio_stream/include/http_stream.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ typedef struct {
bundle for server verification, must be enabled in menuconfig */
int request_size; /*!< Request data size each time from `http_client`
Defaults use DEFAULT_ELEMENT_BUFFER_LENGTH if set to 0
Need care this setting if audio frame size is small and want low latency playback */
Need care this setting if audio frame size is small and want low latency playback */
int request_range_size; /*!< Range size setting for header `Range: bytes=start-end`
Request full range of resource if set to 0
Range size bigger than request size is recommended */
Expand Down

0 comments on commit aea0890

Please sign in to comment.