summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEn-Shuo Hsu <enshuo@chromium.org>2019-06-21 19:45:20 +0800
committerchrome-bot <chrome-bot@chromium.org>2019-06-25 09:20:12 -0700
commit640985b70d3e66d4fbe958919df9d84e980e8cb1 (patch)
treef7c5b9c27c52b050a3a607a8a4edfbeb52331a50
parentd5d66d3d0fa411d99d019c950f3ecbacd36182eb (diff)
downloadadhd-640985b70d3e66d4fbe958919df9d84e980e8cb1.tar.gz
CRAS: Format cras_rclient
Reformat codes with the .clang-format we just introduced. To format whole files provided in-place: clang-format -i -style=file [<file> ...] BUG=chromium:950858 TEST=Add directory to check_format_error and run FEATURES="test" USE=asan emerge-${BOARD} -v media-sound/adhd Change-Id: I9652e4f683422331010109fc4168a974bf9c4f15 Reviewed-on: https://chromium-review.googlesource.com/1670834 Tested-by: En-Shuo Hsu <enshuo@google.com> Commit-Ready: En-Shuo Hsu <enshuo@google.com> Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org> Reviewed-by: Yu-Hsuan Hsu <yuhsuan@chromium.org>
-rw-r--r--cras/src/server/cras_rclient.c9
-rw-r--r--cras/src/server/cras_rclient.h7
2 files changed, 5 insertions, 11 deletions
diff --git a/cras/src/server/cras_rclient.c b/cras/src/server/cras_rclient.c
index 4a797b90..63e20bec 100644
--- a/cras/src/server/cras_rclient.c
+++ b/cras/src/server/cras_rclient.c
@@ -34,9 +34,8 @@ void cras_rclient_destroy(struct cras_rclient *client)
/* Entry point for handling a message from the client. Called from the main
* server context. */
int cras_rclient_buffer_from_client(struct cras_rclient *client,
- const uint8_t *buf,
- size_t buf_len,
- int fd) {
+ const uint8_t *buf, size_t buf_len, int fd)
+{
struct cras_server_message *msg = (struct cras_server_message *)buf;
if (buf_len < sizeof(*msg))
@@ -49,10 +48,8 @@ int cras_rclient_buffer_from_client(struct cras_rclient *client,
/* Sends a message to the client. */
int cras_rclient_send_message(const struct cras_rclient *client,
- const struct cras_client_message *msg,
- int *fds,
+ const struct cras_client_message *msg, int *fds,
unsigned int num_fds)
{
return client->ops->send_message_to_client(client, msg, fds, num_fds);
}
-
diff --git a/cras/src/server/cras_rclient.h b/cras/src/server/cras_rclient.h
index 61815324..c18c8c56 100644
--- a/cras/src/server/cras_rclient.h
+++ b/cras/src/server/cras_rclient.h
@@ -69,9 +69,7 @@ void cras_rclient_destroy(struct cras_rclient *client);
* 0 on success, otherwise a negative error code.
*/
int cras_rclient_buffer_from_client(struct cras_rclient *client,
- const uint8_t *buf,
- size_t buf_len,
- int fd);
+ const uint8_t *buf, size_t buf_len, int fd);
/* Sends a message to the client.
* Args:
@@ -83,8 +81,7 @@ int cras_rclient_buffer_from_client(struct cras_rclient *client,
* number of bytes written on success, otherwise a negative error code.
*/
int cras_rclient_send_message(const struct cras_rclient *client,
- const struct cras_client_message *msg,
- int *fds,
+ const struct cras_client_message *msg, int *fds,
unsigned int num_fds);
#endif /* CRAS_RCLIENT_H_ */