Skip to content

Commit 216fb3e

Browse files
committed
Simplify 'Firebird' namespace usage in remote.
1 parent e78b721 commit 216fb3e

File tree

9 files changed

+256
-250
lines changed

9 files changed

+256
-250
lines changed

src/remote/client/interface.cpp

Lines changed: 91 additions & 91 deletions
Large diffs are not rendered by default.

src/remote/inet.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ class Select
256256
slct_ready(*getDefaultMemoryPool())
257257
{ }
258258

259-
explicit Select(Firebird::MemoryPool& pool)
259+
explicit Select(MemoryPool& pool)
260260
: slct_time(0), slct_count(0), slct_poll(pool), slct_ready(pool)
261261
{ }
262262
#else
@@ -266,7 +266,7 @@ class Select
266266
memset(&slct_fdset, 0, sizeof slct_fdset);
267267
}
268268

269-
explicit Select(Firebird::MemoryPool& /*pool*/)
269+
explicit Select(MemoryPool& /*pool*/)
270270
: slct_time(0), slct_count(0), slct_width(0)
271271
{
272272
memset(&slct_fdset, 0, sizeof slct_fdset);
@@ -616,7 +616,7 @@ ULONG INET_remote_buffer;
616616
static GlobalPtr<Mutex> init_mutex;
617617
static volatile bool INET_initialized = false;
618618
static volatile bool INET_shutting_down = false;
619-
static Firebird::GlobalPtr<Select> INET_select;
619+
static GlobalPtr<Select> INET_select;
620620
static rem_port* inet_async_receive = NULL;
621621

622622

@@ -632,7 +632,7 @@ rem_port* INET_analyze(ClntAuthBlock* cBlock,
632632
ClumpletReader &dpb,
633633
RefPtr<const Config>* config,
634634
const PathName* ref_db_name,
635-
Firebird::ICryptKeyCallback* cryptCb,
635+
ICryptKeyCallback* cryptCb,
636636
int af)
637637
{
638638
/**************************************
@@ -3080,7 +3080,7 @@ static bool packet_receive(rem_port* port, UCHAR* buffer, SSHORT buffer_length,
30803080
if (n > 0 && port->port_crypt_plugin)
30813081
{
30823082
port->port_crypt_plugin->decrypt(&st, n, buffer, buffer);
3083-
if (st.getState() & Firebird::IStatus::STATE_ERRORS)
3083+
if (st.getState() & IStatus::STATE_ERRORS)
30843084
{
30853085
status_exception::raise(&st);
30863086
}
@@ -3164,7 +3164,7 @@ static bool packet_send( rem_port* port, const SCHAR* buffer, SSHORT buffer_leng
31643164

31653165
char* d = b.getBuffer(buffer_length);
31663166
port->port_crypt_plugin->encrypt(&st, buffer_length, data, d);
3167-
if (st.getState() & Firebird::IStatus::STATE_ERRORS)
3167+
if (st.getState() & IStatus::STATE_ERRORS)
31683168
{
31693169
status_exception::raise(&st);
31703170
}

src/remote/merge.cpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@
2929
#include "../yvalve/gds_proto.h"
3030
#include "../common/classes/DbImplementation.h"
3131

32+
using namespace Firebird;
33+
3234
inline void PUT_WORD(UCHAR*& ptr, USHORT value)
3335
{
3436
*ptr++ = static_cast<UCHAR>(value);
@@ -37,7 +39,7 @@ inline void PUT_WORD(UCHAR*& ptr, USHORT value)
3739

3840
#define PUT(ptr, value) *(ptr)++ = value;
3941

40-
static ISC_STATUS merge_setup(const Firebird::ClumpletReader&, UCHAR**, const UCHAR* const, FB_SIZE_T);
42+
static ISC_STATUS merge_setup(const ClumpletReader&, UCHAR**, const UCHAR* const, FB_SIZE_T);
4143

4244

4345
USHORT MERGE_database_info(const UCHAR* const in,
@@ -69,7 +71,7 @@ USHORT MERGE_database_info(const UCHAR* const in,
6971
const UCHAR* const end = out + buf_length;
7072

7173
UCHAR mergeLevel = 0;
72-
Firebird::ClumpletReader input(Firebird::ClumpletReader::InfoResponse, in, buf_length);
74+
ClumpletReader input(ClumpletReader::InfoResponse, in, buf_length);
7375
while (!input.isEof())
7476
{
7577
bool flStop = true;
@@ -149,7 +151,7 @@ USHORT MERGE_database_info(const UCHAR* const in,
149151
case fb_info_implementation:
150152
if (merge_setup(input, &out, end, 6))
151153
return 0;
152-
Firebird::DbImplementation::current.stuff(&out);
154+
DbImplementation::current.stuff(&out);
153155
PUT(out, (UCHAR) class_);
154156
PUT(out, mergeLevel);
155157
break;
@@ -183,7 +185,7 @@ USHORT MERGE_database_info(const UCHAR* const in,
183185
return 0; // error - missing isc_info_end item
184186
}
185187

186-
static ISC_STATUS merge_setup(const Firebird::ClumpletReader& input, UCHAR** out, const UCHAR* const end,
188+
static ISC_STATUS merge_setup(const ClumpletReader& input, UCHAR** out, const UCHAR* const end,
187189
FB_SIZE_T delta_length)
188190
{
189191
/**************************************

src/remote/os/win32/xnet.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ rem_port* XNET_analyze(ClntAuthBlock* cBlock,
237237
const PathName& file_name,
238238
bool uv_flag,
239239
RefPtr<const Config>* config,
240-
const Firebird::PathName* ref_db_name)
240+
const PathName* ref_db_name)
241241
{
242242
/**************************************
243243
*
@@ -362,10 +362,10 @@ rem_port* XNET_analyze(ClntAuthBlock* cBlock,
362362
case op_response:
363363
try
364364
{
365-
Firebird::LocalStatus warning; // Ignore connect warnings for a while
365+
LocalStatus warning; // Ignore connect warnings for a while
366366
REMOTE_check_response(&warning, rdb, packet);
367367
}
368-
catch (const Firebird::Exception&)
368+
catch (const Exception&)
369369
{
370370
disconnect(port);
371371
delete rdb;
@@ -406,7 +406,7 @@ rem_port* XNET_analyze(ClntAuthBlock* cBlock,
406406

407407
rem_port* XNET_connect(PACKET* packet,
408408
USHORT flag,
409-
Firebird::RefPtr<const Config>* config)
409+
RefPtr<const Config>* config)
410410
{
411411
/**************************************
412412
*
@@ -1109,7 +1109,7 @@ rem_port* XnetClientEndPoint::connect_client(PACKET* packet, const RefPtr<const
11091109
*
11101110
**************************************/
11111111

1112-
const Firebird::RefPtr<const Config>& conf(config ? *config : Config::getDefaultConfig());
1112+
const RefPtr<const Config>& conf(config ? *config : Config::getDefaultConfig());
11131113

11141114
if (!xnet_initialized)
11151115
{

src/remote/protocol.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1031,7 +1031,7 @@ bool_t xdr_protocol(RemoteXdr* xdrs, PACKET* p)
10311031

10321032
if (xdrs->x_op == XDR_DECODE)
10331033
{
1034-
Firebird::Arg::StatusVector sv(ptr->value());
1034+
Arg::StatusVector sv(ptr->value());
10351035
LocalStatus to;
10361036
sv.copyTo(&to);
10371037
delete ptr;
@@ -1812,8 +1812,8 @@ static bool_t xdr_slice(RemoteXdr* xdrs, lstring* slice, /*USHORT sdl_length,*/
18121812

18131813
struct sdl_info info;
18141814
{
1815-
Firebird::LocalStatus ls;
1816-
Firebird::CheckStatusWrapper s(&ls);
1815+
LocalStatus ls;
1816+
CheckStatusWrapper s(&ls);
18171817
if (SDL_info(&s, sdl, &info, 0))
18181818
return FALSE;
18191819
}

0 commit comments

Comments
 (0)