From 7a1e167ca90a2d3c708ea6ef3961402e5db2286b Mon Sep 17 00:00:00 2001 From: maroy Date: Tue, 23 Nov 2004 15:39:58 +0000 Subject: [PATCH] dumping trivial errors to cerr --- livesupport/products/scheduler/src/PlaylistEvent.cxx | 7 +++++-- .../scheduler/src/PlaylistEventContainerTest.cxx | 11 ++++++++--- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/livesupport/products/scheduler/src/PlaylistEvent.cxx b/livesupport/products/scheduler/src/PlaylistEvent.cxx index 8851bbaa6..3b1026201 100644 --- a/livesupport/products/scheduler/src/PlaylistEvent.cxx +++ b/livesupport/products/scheduler/src/PlaylistEvent.cxx @@ -21,8 +21,8 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - Author : $Author: fgerlits $ - Version : $Revision: 1.3 $ + Author : $Author: maroy $ + Version : $Revision: 1.4 $ Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/products/scheduler/src/PlaylistEvent.cxx,v $ ------------------------------------------------------------------------------*/ @@ -39,6 +39,8 @@ #error need unistd.h #endif +#include + #include "LiveSupport/Core/TimeConversion.h" #include "LiveSupport/Core/SessionId.h" @@ -109,6 +111,7 @@ PlaylistEvent :: start(void) throw () audioPlayer->playThis(*playlist->getUri()); audioPlayer->start(); } catch (std::invalid_argument &e) { + std::cerr << e.what() << std::endl; // TODO: handle error? } } diff --git a/livesupport/products/scheduler/src/PlaylistEventContainerTest.cxx b/livesupport/products/scheduler/src/PlaylistEventContainerTest.cxx index 536756303..d3d2cfef2 100644 --- a/livesupport/products/scheduler/src/PlaylistEventContainerTest.cxx +++ b/livesupport/products/scheduler/src/PlaylistEventContainerTest.cxx @@ -21,8 +21,8 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - Author : $Author: fgerlits $ - Version : $Revision: 1.2 $ + Author : $Author: maroy $ + Version : $Revision: 1.3 $ Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/products/scheduler/src/PlaylistEventContainerTest.cxx,v $ ------------------------------------------------------------------------------*/ @@ -156,7 +156,12 @@ PlaylistEventContainerTest :: setUp(void) throw () CPPUNIT_FAIL("error parsing configuration file"); } - scheduleFactory->install(); + try { + scheduleFactory->install(); + } catch (std::exception &e) { + std::cerr << e.what() << std::endl; + CPPUNIT_FAIL("can't install schedule factory"); + } audioPlayer->initialize(); if (!(sessionId = authentication->login("root", "q"))) {