8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-24 08:43:03 +01:00

Style: got rid of spaces around C++ cast operators

Put the static (private) functions out of the extern "C" block.
This commit is contained in:
robocop 2003-09-15 11:14:47 +00:00
parent 96571b436d
commit 1affa8b81c

View File

@ -149,8 +149,6 @@ extern int ib_printf();
#define BSTR_output 1 #define BSTR_output 1
#define BSTR_alloc 2 #define BSTR_alloc 2
extern "C" {
static int dump(GDS_QUAD *, FRBRD *, FRBRD *, IB_FILE *); static int dump(GDS_QUAD *, FRBRD *, FRBRD *, IB_FILE *);
static int edit(GDS_QUAD *, FRBRD *, FRBRD *, SSHORT, SCHAR *); static int edit(GDS_QUAD *, FRBRD *, FRBRD *, SSHORT, SCHAR *);
static int get_ods_version(FRBRD **, USHORT *, USHORT *); static int get_ods_version(FRBRD **, USHORT *, USHORT *);
@ -263,6 +261,7 @@ static const TEXT *const impl_implementation[] = {
}; };
extern "C" {
#ifdef SHLIB_DEFS #ifdef SHLIB_DEFS
#define strlen (*_libgds_strlen) #define strlen (*_libgds_strlen)
@ -541,9 +540,10 @@ int API_ROUTINE isc_modify_dpb(SCHAR** dpb,
{ {
/************************************** /**************************************
* *
* i s c _ e x p a n d _ d p b * i s c _ m o d i f y _ d p b
* *
************************************** **************************************
* CVC: this description seems copy/paste from isc_expand_dpb.
* *
* Functional description * Functional description
* Extend a database parameter block dynamically * Extend a database parameter block dynamically
@ -1293,8 +1293,7 @@ int API_ROUTINE gds__version(
if (isc_database_info(status_vector, if (isc_database_info(status_vector,
handle, handle,
sizeof(info), sizeof(info),
reinterpret_cast < char *>(const_cast < reinterpret_cast<char*>(const_cast<UCHAR*>(info)),
UCHAR * >(info)),
buf_len, reinterpret_cast<char*>(buf))) { buf_len, reinterpret_cast<char*>(buf))) {
if (buf != buffer) if (buf != buffer)
gds__free((SLONG *) buf); gds__free((SLONG *) buf);
@ -1503,8 +1502,10 @@ int API_ROUTINE BLOB_close(BSTREAM * bstream)
if (l > 0) if (l > 0)
if (gds__put_segment(status_vector, &bstream->bstr_blob, l, if (gds__put_segment(status_vector, &bstream->bstr_blob, l,
bstream->bstr_buffer)) bstream->bstr_buffer))
{
return FALSE; return FALSE;
} }
}
gds__close_blob(status_vector, &bstream->bstr_blob); gds__close_blob(status_vector, &bstream->bstr_blob);
@ -1886,14 +1887,18 @@ BSTREAM *API_ROUTINE Bopen(GDS_QUAD * blob_id,
if (gds__create_blob2(status_vector, &database, &transaction, &blob, if (gds__create_blob2(status_vector, &database, &transaction, &blob,
blob_id, bpb_length, blob_id, bpb_length,
reinterpret_cast<char*>(bpb))) reinterpret_cast<char*>(bpb)))
{
return NULL; return NULL;
} }
}
else if (*mode == 'r' || *mode == 'R') { else if (*mode == 'r' || *mode == 'R') {
if (gds__open_blob2(status_vector, &database, &transaction, &blob, if (gds__open_blob2(status_vector, &database, &transaction, &blob,
blob_id, bpb_length, blob_id, bpb_length,
reinterpret_cast<char*>(bpb))) reinterpret_cast<char*>(bpb)))
{
return NULL; return NULL;
} }
}
else else
return NULL; return NULL;
@ -2003,6 +2008,8 @@ int API_ROUTINE BLOB_put(SCHAR x, BSTREAM * bstream)
return TRUE; return TRUE;
} }
} // extern "C"
#ifdef VMS #ifdef VMS
static display(GDS_QUAD * blob_id, void *database, void *transaction) static display(GDS_QUAD * blob_id, void *database, void *transaction)
@ -2230,8 +2237,7 @@ static int get_ods_version(
isc_database_info(status_vector, isc_database_info(status_vector,
handle, handle,
sizeof(ods_info), sizeof(ods_info),
reinterpret_cast < char *>(const_cast < reinterpret_cast<char*>(const_cast<UCHAR*>(ods_info)),
UCHAR * >(ods_info)),
sizeof(buffer), reinterpret_cast<char*>(buffer)); sizeof(buffer), reinterpret_cast<char*>(buffer));
if (status_vector[1]) if (status_vector[1])
@ -2324,5 +2330,3 @@ static int load(
return TRUE; return TRUE;
} }
} // extern "C"