summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-12-10 00:56:48 +0000
committerCarl Hetherington <cth@carlh.net>2014-12-10 00:56:48 +0000
commit5c93e50af883f02eadcf9a7bfe9cbfabbb3be844 (patch)
tree82a2f835c082a3104e8002139463b07650cd6390 /src
parent0c32e4bfd1ad6418dad2a504a4bf6cdea48f6d75 (diff)
Trim unused stuff.
Diffstat (limited to 'src')
-rw-r--r--src/lib/util.cc56
-rw-r--r--src/lib/util.h1
2 files changed, 2 insertions, 55 deletions
diff --git a/src/lib/util.cc b/src/lib/util.cc
index 20b7ba470..e03b47568 100644
--- a/src/lib/util.cc
+++ b/src/lib/util.cc
@@ -88,20 +88,14 @@ using std::setfill;
using std::ostream;
using std::endl;
using std::vector;
-using std::hex;
-using std::setw;
-using std::ios;
using std::min;
using std::max;
using std::list;
using std::multimap;
-using std::map;
using std::istream;
-using std::numeric_limits;
using std::pair;
using std::cout;
using std::bad_alloc;
-using std::streampos;
using std::set_terminate;
using boost::shared_ptr;
using boost::thread;
@@ -130,9 +124,9 @@ seconds_to_hms (int s)
SafeStringStream hms;
hms << h << N_(":");
hms.width (2);
- hms << std::setfill ('0') << m << N_(":");
+ hms << setfill ('0') << m << N_(":");
hms.width (2);
- hms << std::setfill ('0') << s;
+ hms << setfill ('0') << s;
return hms.str ();
}
@@ -823,52 +817,6 @@ tidy_for_filename (string f)
return t;
}
-map<string, string>
-split_get_request (string url)
-{
- enum {
- AWAITING_QUESTION_MARK,
- KEY,
- VALUE
- } state = AWAITING_QUESTION_MARK;
-
- map<string, string> r;
- string k;
- string v;
- for (size_t i = 0; i < url.length(); ++i) {
- switch (state) {
- case AWAITING_QUESTION_MARK:
- if (url[i] == '?') {
- state = KEY;
- }
- break;
- case KEY:
- if (url[i] == '=') {
- v.clear ();
- state = VALUE;
- } else {
- k += url[i];
- }
- break;
- case VALUE:
- if (url[i] == '&') {
- r.insert (make_pair (k, v));
- k.clear ();
- state = KEY;
- } else {
- v += url[i];
- }
- break;
- }
- }
-
- if (state == VALUE) {
- r.insert (make_pair (k, v));
- }
-
- return r;
-}
-
dcp::Size
fit_ratio_within (float ratio, dcp::Size full_frame, int round)
{
diff --git a/src/lib/util.h b/src/lib/util.h
index b6817f883..1d04d358b 100644
--- a/src/lib/util.h
+++ b/src/lib/util.h
@@ -70,7 +70,6 @@ extern boost::filesystem::path mo_path ();
extern std::string tidy_for_filename (std::string);
extern dcp::Size fit_ratio_within (float ratio, dcp::Size, int);
extern std::string entities_to_text (std::string e);
-extern std::map<std::string, std::string> split_get_request (std::string url);
extern int dcp_audio_frame_rate (int);
extern int stride_round_up (int, int const *, int);
extern int round_to (float n, int r);