From 1f3a000bfa440bbbad404a5eeff992099b588acd Mon Sep 17 00:00:00 2001 From: Justin Viiret Date: Wed, 29 Mar 2017 15:08:16 +1100 Subject: [PATCH] dump_util: move into namespace ue2 --- src/util/dump_util.cpp | 6 +++++- src/util/dump_util.h | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/util/dump_util.cpp b/src/util/dump_util.cpp index 5b961367..782cba7a 100644 --- a/src/util/dump_util.cpp +++ b/src/util/dump_util.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Intel Corporation + * Copyright (c) 2016-2017, Intel Corporation * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -33,6 +33,8 @@ using namespace std; +namespace ue2 { + FILE *fopen_or_throw(const char *path, const char *mode) { FILE *f = fopen(path, mode); if (!f) { @@ -40,3 +42,5 @@ FILE *fopen_or_throw(const char *path, const char *mode) { } return f; } + +} // namespace ue2 diff --git a/src/util/dump_util.h b/src/util/dump_util.h index 487d2e7c..f5ebe94a 100644 --- a/src/util/dump_util.h +++ b/src/util/dump_util.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Intel Corporation + * Copyright (c) 2016-2017, Intel Corporation * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -31,9 +31,13 @@ #include +namespace ue2 { + /** * Same as fopen(), but on error throws an exception rather than returning NULL. */ FILE *fopen_or_throw(const char *path, const char *mode); +} // namespace ue2 + #endif