This is an automated email from the ASF dual-hosted git repository. pkarashchenko pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git
The following commit(s) were added to refs/heads/master by this push: new c694d8d90 system/composite_main.c: Convert fprintf -> dprintf c694d8d90 is described below commit c694d8d90fe62e3f429309acd4e409870f58289e Author: Ville Juven <ville.ju...@unikie.com> AuthorDate: Thu Mar 30 12:18:27 2023 +0300 system/composite_main.c: Convert fprintf -> dprintf CONFIG_FILE_STREAMS now defaults to 'n' when DEFAULT_SMALL is enabled. This is a good change, but this source file fails to compile when file streams are disabled. Fix this by using dprintf. --- system/composite/composite_main.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/system/composite/composite_main.c b/system/composite/composite_main.c index 3bc41d453..22201cb9b 100644 --- a/system/composite/composite_main.c +++ b/system/composite/composite_main.c @@ -398,7 +398,7 @@ int main(int argc, FAR char *argv[]) if (g_composite.cmphandle) { - fprintf(stderr, "conn_main: ERROR: Already connected\n"); + dprintf(STDERR_FILENO, "conn_main: ERROR: Already connected\n"); return 1; } @@ -410,7 +410,8 @@ int main(int argc, FAR char *argv[]) } else if (argc > 2) { - fprintf(stderr, "conn_main: ERROR: Too many arguments: %d\n", argc); + dprintf(STDERR_FILENO, "conn_main: ERROR: Too many arguments: %d\n", + argc); return EXIT_FAILURE; } @@ -513,7 +514,7 @@ int disconn_main(int argc, char *argv[]) if (!g_composite.cmphandle) { - fprintf(stderr, "disconn_main: ERROR: Not connected\n"); + dprintf(STDERR_FILENO, "disconn_main: ERROR: Not connected\n"); return 1; } @@ -527,7 +528,8 @@ int disconn_main(int argc, char *argv[]) } else if (argc > 2) { - fprintf(stderr, "conn_main: ERROR: Too many arguments: %d\n", argc); + dprintf(STDERR_FILENO, "conn_main: ERROR: Too many arguments: %d\n", + argc); return EXIT_FAILURE; }