summaryrefslogtreecommitdiff
path: root/server/mov_encoder_writer.cc
diff options
context:
space:
mode:
authordeva <deva>2006-08-16 23:49:23 +0000
committerdeva <deva>2006-08-16 23:49:23 +0000
commit347b1d8ed3a4f780f3a5c0d57a04eab05ca517a2 (patch)
treedc21975923fb440c78ee4bbffc645a138071978f /server/mov_encoder_writer.cc
parent6c07f9219bed6ccddc9b65ad40414cf0a9f7d633 (diff)
Replaced the old MiavConfig class with the new Configuration class in all the the appropriate places.
Crippled the MulticastConfiguration class. This must be rewritten to use the new configuration interface.
Diffstat (limited to 'server/mov_encoder_writer.cc')
-rw-r--r--server/mov_encoder_writer.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/server/mov_encoder_writer.cc b/server/mov_encoder_writer.cc
index 8f432ee..54c816d 100644
--- a/server/mov_encoder_writer.cc
+++ b/server/mov_encoder_writer.cc
@@ -40,9 +40,8 @@
#include <errno.h>
#include <string>
-using namespace std;
-#include "miav_config.h"
+#include "configuration.h"
#include "info.h"
#include <time.h>
@@ -60,12 +59,13 @@ MovEncoderWriter::MovEncoderWriter(const char *clientip, const char* cpr,
// Create path and filename
char fname[256];
- string *server_root;
+ std::string server_root;
char birthmonth[3];
char date[32];
// Get server root
- server_root = MIaV::config->readString("server_movie_root");
+ if(MIaV::config->get("server_movie_root", &server_root))
+ MIaV::info->error("Could not read the symbol [server_movie_root] from the conf file!");
// Copy the bytes representing the birth month from the cpr
// [dd][mm][yy]-[nn][nn]
@@ -81,7 +81,7 @@ MovEncoderWriter::MovEncoderWriter(const char *clientip, const char* cpr,
ltime->tm_mon + 1, // Ranging from 0 to 11
ltime->tm_mday);
- sprintf(fname, "%s/%s/%s/%s-%s-", server_root->c_str(), birthmonth, cpr, cpr, date);
+ sprintf(fname, "%s/%s/%s/%s-%s-", server_root.c_str(), birthmonth, cpr, cpr, date);
file = new File(fname, "mpg");