diff options
author | coryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2000-11-08 17:05:23 +0000 |
---|---|---|
committer | coryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2000-11-08 17:05:23 +0000 |
commit | 4c88b77612a3e2a26c2df79e0c18e23e21916e0e (patch) | |
tree | becd611b2d35c19503af00d8d08e55e255839804 /examples | |
parent | 4d844b1f5b5d4c2ea5fcf469d0f76b1ad7119ee1 (diff) | |
download | ATCD-4c88b77612a3e2a26c2df79e0c18e23e21916e0e.tar.gz |
ChangeLogTag:Wed Nov 8 09:02:10 2000 Carlos O'Ryan <coryan@uci.edu>
Diffstat (limited to 'examples')
-rw-r--r-- | examples/IPC_SAP/FILE_SAP/client.cpp | 8 | ||||
-rw-r--r-- | examples/Naming/test_multiple_contexts.cpp | 10 | ||||
-rw-r--r-- | examples/Service_Configurator/IPC-tests/server/Makefile | 6 | ||||
-rw-r--r-- | examples/Service_Configurator/Misc/Makefile | 6 | ||||
-rw-r--r-- | examples/Threads/thread_specific.cpp | 6 | ||||
-rw-r--r-- | examples/Timer_Queue/Makefile | 6 | ||||
-rw-r--r-- | examples/Timer_Queue/Thread_Timer_Queue_Test.cpp | 8 |
7 files changed, 34 insertions, 16 deletions
diff --git a/examples/IPC_SAP/FILE_SAP/client.cpp b/examples/IPC_SAP/FILE_SAP/client.cpp index dacbb126193..2c70d643ece 100644 --- a/examples/IPC_SAP/FILE_SAP/client.cpp +++ b/examples/IPC_SAP/FILE_SAP/client.cpp @@ -7,7 +7,7 @@ ACE_RCSID(FILE_SAP, client, "$Id$") -int +int main (int argc, char *argv[]) { if (argc < 3 || argc > 3) @@ -23,7 +23,7 @@ main (int argc, char *argv[]) ACE_FILE_Connector con; if (con.connect (cli_file, - ACE_FILE_Addr (argv[1]), + ACE_FILE_Addr (argv[1]), 0, ACE_Addr::sap_any, 0, O_RDWR|O_APPEND|O_CREAT, 0666) == -1) @@ -49,7 +49,7 @@ main (int argc, char *argv[]) else ACE_OS::printf ("fileinfo : mode = %o\nno of links = %lu\nsize = %lu\n", fileinfo.mode_ & 0777, - fileinfo.nlink_, + ACE_static_cast(unsigned long,fileinfo.nlink_), fileinfo.size_); off_t fpos = cli_file.position (); @@ -62,7 +62,7 @@ main (int argc, char *argv[]) else ACE_OS::printf ("current filepointer is at %ld\n", fpos); - + if (cli_file.position (0, SEEK_SET) == -1) ACE_ERROR_RETURN ((LM_ERROR, diff --git a/examples/Naming/test_multiple_contexts.cpp b/examples/Naming/test_multiple_contexts.cpp index e2f6658a96d..a8a028a3c41 100644 --- a/examples/Naming/test_multiple_contexts.cpp +++ b/examples/Naming/test_multiple_contexts.cpp @@ -31,10 +31,10 @@ int main (int, char *[]) char address_arg1[BUFSIZ]; char address_arg2[BUFSIZ]; ACE_OS::sprintf (address_arg1, - "-b%d", + "-b%ld", ACE_DEFAULT_BASE_ADDR_1); - const char *m_argv[] = + const char *m_argv[] = { "MyName1", "-cNODE_LOCAL", @@ -45,7 +45,7 @@ int main (int, char *[]) sizeof (m_argv) / sizeof (char *) -1; ACE_OS::sprintf (address_arg2, - "-b%d", + "-b%ld", ACE_DEFAULT_BASE_ADDR_2); const char *n_argv[] = { @@ -66,7 +66,7 @@ int main (int, char *[]) "(%P) opened with %d\n", i)); - if (i != 0) + if (i != 0) return -1; name_options1->parse_args (n_argc, @@ -77,7 +77,7 @@ int main (int, char *[]) ACE_DEBUG ((LM_DEBUG, "(%P) 1 opened with %d\n", i)); - if (i != 0) + if (i != 0) return -1; return 0; diff --git a/examples/Service_Configurator/IPC-tests/server/Makefile b/examples/Service_Configurator/IPC-tests/server/Makefile index ee02cc2accf..6278253914f 100644 --- a/examples/Service_Configurator/IPC-tests/server/Makefile +++ b/examples/Service_Configurator/IPC-tests/server/Makefile @@ -48,6 +48,12 @@ include $(ACE_ROOT)/include/makeinclude/rules.local.GNU # Local targets #---------------------------------------------------------------------------- +ifeq ($(static_libs_only),1) +$(VBIN): $(VLIB) +else +$(VBIN): $(VSHLIB) +endif + #---------------------------------------------------------------------------- # Dependencies #---------------------------------------------------------------------------- diff --git a/examples/Service_Configurator/Misc/Makefile b/examples/Service_Configurator/Misc/Makefile index 83adf865ae3..8d794b60e14 100644 --- a/examples/Service_Configurator/Misc/Makefile +++ b/examples/Service_Configurator/Misc/Makefile @@ -40,6 +40,12 @@ include $(ACE_ROOT)/include/makeinclude/rules.local.GNU # Local targets #---------------------------------------------------------------------------- +ifeq ($(static_libs_only),1) +$(VBIN): $(VLIB) +else +$(VBIN): $(VSHLIB) +endif + #---------------------------------------------------------------------------- # Dependencies #---------------------------------------------------------------------------- diff --git a/examples/Threads/thread_specific.cpp b/examples/Threads/thread_specific.cpp index 8176020141a..54397282388 100644 --- a/examples/Threads/thread_specific.cpp +++ b/examples/Threads/thread_specific.cpp @@ -61,7 +61,7 @@ worker (void *c) 0); if (ACE_Thread::setspecific (key, (void *) ip) == -1) - ACE_ERROR ((LM_ERROR, + ACE_ERROR ((LM_ERROR, "(%t) %p\n", "ACE_Thread::setspecific")); @@ -120,8 +120,8 @@ worker (void *c) // Use the guard to serialize access to printf... ACE_GUARD_RETURN (ACE_Thread_Mutex, ace_mon, printf_lock, 0); - ACE_OS::printf ("(%u) errno = %d, lineno = %d, flags = %d\n", - handle, + ACE_OS::printf ("(%lu) errno = %d, lineno = %d, flags = %d\n", + ACE_static_cast(unsigned long,handle), tss_error->error (), tss_error->line (), tss_error->flags ()); diff --git a/examples/Timer_Queue/Makefile b/examples/Timer_Queue/Makefile index c0f48c6e25f..49b34955450 100644 --- a/examples/Timer_Queue/Makefile +++ b/examples/Timer_Queue/Makefile @@ -44,6 +44,12 @@ include $(ACE_ROOT)/include/makeinclude/rules.local.GNU # Local targets #---------------------------------------------------------------------------- +ifeq ($(static_libs_only),1) +$(VBIN): $(VLIB) +else +$(VBIN): $(VSHLIB) +endif + #---------------------------------------------------------------------------- # Dependencies #---------------------------------------------------------------------------- diff --git a/examples/Timer_Queue/Thread_Timer_Queue_Test.cpp b/examples/Timer_Queue/Thread_Timer_Queue_Test.cpp index 93aef7b8b87..0525f865d6d 100644 --- a/examples/Timer_Queue/Thread_Timer_Queue_Test.cpp +++ b/examples/Timer_Queue/Thread_Timer_Queue_Test.cpp @@ -90,8 +90,8 @@ Handler::handle_timeout (const ACE_Time_Value ¤t_time, // No need to protect this printf is always called from a Async safe // point. - ACE_OS::printf ("\nexpiring timer %d at %u.%07.7u secs\n" - "\tthere was a %u.%07.7u secs delay\n", + ACE_OS::printf ("\nexpiring timer %d at %lu.%7.7lu secs\n" + "\tthere was a %lu.%7.7lu secs delay\n", this->id_, current_time.sec (), current_time.usec (), @@ -178,7 +178,7 @@ Input_Task::add_timer (void *argument) int Input_Task::cancel_timer (void *argument) { - return this->queue_->cancel (*ACE_reinterpret_cast (int *, + return this->queue_->cancel (*ACE_reinterpret_cast (int *, argument)); } @@ -214,7 +214,7 @@ Input_Task::shutdown_timer (void *argument) // Cancel the thread timer queue task "preemptively." if (ACE_Thread::cancel (this->queue_->thr_id ()) == -1) ACE_ERROR ((LM_ERROR, - "%p\n", + "%p\n", "cancel")); #endif /* ACE_LACKS_PTHREAD_CANCEL */ |