aboutsummaryrefslogtreecommitdiff
path: root/src/sersve.rs
diff options
context:
space:
mode:
authorTill Hoeppner2014-11-26 23:27:57 +0100
committerTill Hoeppner2014-11-26 23:27:57 +0100
commitca5a2b6e222ff556b8bcab4f20ec9fecc4e81bc9 (patch)
tree7f5fbdf0ba055bf066902fcef27c2a7ccad53f6f /src/sersve.rs
parentae2651ee86f604757b5474dee8b343d28f0fce75 (diff)
downloadsersve-ca5a2b6e222ff556b8bcab4f20ec9fecc4e81bc9.tar.gz
sersve-ca5a2b6e222ff556b8bcab4f20ec9fecc4e81bc9.tar.xz
sersve-ca5a2b6e222ff556b8bcab4f20ec9fecc4e81bc9.zip
Change defaults, errors and build setup
Diffstat (limited to 'src/sersve.rs')
-rw-r--r--src/sersve.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sersve.rs b/src/sersve.rs
index 1d6e91c..a38a44a 100644
--- a/src/sersve.rs
+++ b/src/sersve.rs
@@ -196,7 +196,7 @@ fn main() {
matches.opt_str("c").map(|conf_file| {
let conf_file = File::open(&Path::new(conf_file));
- //conf_file.map_err(|e| panic!("{}", e.desc));
+ conf_file.as_ref().map_err::<()>(|e| panic!("{}", e.desc)).unwrap();
let json = match json::from_reader(&mut conf_file.ok().unwrap()) {
Ok(Json::Object(o)) => o,
_ => panic!("Invalid configuration file. Doesn't contain top-level object.")