Search
j0ke.net Open Build Service
>
Projects
>
home:netmax
>
pdns-recursor
> pdns-recursor-3.1.4_char_casting.patch
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File pdns-recursor-3.1.4_char_casting.patch of Package pdns-recursor (Revision 3)
Currently displaying revision
3
,
show latest
------------------------------------------------------------------------ r964 | ahu | 2007-02-27 20:49:45 +0100 (Tue, 27 Feb 2007) | 3 lines Changed paths: M /trunk/pdns/pdns/qtype.cc M /trunk/pdns/pdns/qtype.hh M /trunk/pdns/pdns/sstuff.hh some const char* correctness disocovered by darix on recent g++ snapshots ------------------------------------------------------------------------ Index: qtype.hh =================================================================== --- qtype.hh (revision 963) +++ qtype.hh (revision 964) @@ -76,7 +76,7 @@ private: short int code; typedef pair<string,int> namenum; - void insert(char *p, int n); + void insert(const char *p, int n); static vector<namenum> names; static bool uninit; Index: sstuff.hh =================================================================== --- sstuff.hh (revision 963) +++ sstuff.hh (revision 964) @@ -24,9 +24,9 @@ class NetworkError : public runtime_error { public: - NetworkError(string why="Network Error") : runtime_error(why.c_str()) + NetworkError(const string& why="Network Error") : runtime_error(why.c_str()) {} - NetworkError(char *why="Network Error") : runtime_error(why) + NetworkError(const char *why="Network Error") : runtime_error(why) {} }; Index: qtype.cc =================================================================== --- qtype.cc (revision 963) +++ qtype.cc (revision 964) @@ -29,7 +29,7 @@ bool QType::uninit=true; vector<QType::namenum> QType::names; -void QType::insert(char *p, int n) +void QType::insert(const char *p, int n) { names.push_back(make_pair(string(p),n)); }