summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--c/src/libnetworking/rtems_webserver/uemf.c7
-rw-r--r--c/src/libnetworking/rtems_webserver/webmain.c8
-rw-r--r--cpukit/httpd/uemf.c7
-rw-r--r--cpukit/httpd/webmain.c8
4 files changed, 24 insertions, 6 deletions
diff --git a/c/src/libnetworking/rtems_webserver/uemf.c b/c/src/libnetworking/rtems_webserver/uemf.c
index a9302f989c..ef7c8f3135 100644
--- a/c/src/libnetworking/rtems_webserver/uemf.c
+++ b/c/src/libnetworking/rtems_webserver/uemf.c
@@ -30,6 +30,10 @@ int emfInst; /* Application instance handle */
void error(E_ARGS_DEC, int flags, char_t *fmt, ...)
{
+ va_list arglist;
+
+ va_start(arglist, fmt);
+
if (flags & E_LOG) {
/* Log error message */
@@ -40,6 +44,9 @@ void error(E_ARGS_DEC, int flags, char_t *fmt, ...)
/* Display message to the user */
}
+
+ vprintf (fmt, arglist);
+ va_end(arglist);
}
/******************************************************************************/
diff --git a/c/src/libnetworking/rtems_webserver/webmain.c b/c/src/libnetworking/rtems_webserver/webmain.c
index f61b649ced..9f467b5167 100644
--- a/c/src/libnetworking/rtems_webserver/webmain.c
+++ b/c/src/libnetworking/rtems_webserver/webmain.c
@@ -113,8 +113,10 @@ rtems_httpd_daemon()
/*
* Initialize the web server
*/
- if (initWebs() < 0) {
- rtems_panic("Unable to initialize Web server !!\n");
+ while (initWebs() < 0) {
+ printf("\nUnable to initialize Web server !!\n"
+ " Suspending the task. Resume to try again.\n");
+ rtems_task_suspend( RTEMS_SELF);
}
/*
@@ -137,7 +139,7 @@ rtems_httpd_daemon()
memLeaks();
#endif
bclose();
- rtems_task_delete( RTEMS_SELF );
+ rtems_task_delete( RTEMS_SELF );
}
/******************************************************************************/
diff --git a/cpukit/httpd/uemf.c b/cpukit/httpd/uemf.c
index a9302f989c..ef7c8f3135 100644
--- a/cpukit/httpd/uemf.c
+++ b/cpukit/httpd/uemf.c
@@ -30,6 +30,10 @@ int emfInst; /* Application instance handle */
void error(E_ARGS_DEC, int flags, char_t *fmt, ...)
{
+ va_list arglist;
+
+ va_start(arglist, fmt);
+
if (flags & E_LOG) {
/* Log error message */
@@ -40,6 +44,9 @@ void error(E_ARGS_DEC, int flags, char_t *fmt, ...)
/* Display message to the user */
}
+
+ vprintf (fmt, arglist);
+ va_end(arglist);
}
/******************************************************************************/
diff --git a/cpukit/httpd/webmain.c b/cpukit/httpd/webmain.c
index f61b649ced..9f467b5167 100644
--- a/cpukit/httpd/webmain.c
+++ b/cpukit/httpd/webmain.c
@@ -113,8 +113,10 @@ rtems_httpd_daemon()
/*
* Initialize the web server
*/
- if (initWebs() < 0) {
- rtems_panic("Unable to initialize Web server !!\n");
+ while (initWebs() < 0) {
+ printf("\nUnable to initialize Web server !!\n"
+ " Suspending the task. Resume to try again.\n");
+ rtems_task_suspend( RTEMS_SELF);
}
/*
@@ -137,7 +139,7 @@ rtems_httpd_daemon()
memLeaks();
#endif
bclose();
- rtems_task_delete( RTEMS_SELF );
+ rtems_task_delete( RTEMS_SELF );
}
/******************************************************************************/