8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-22 16:43:03 +01:00
This commit is contained in:
asfernandes 2009-07-23 00:56:28 +00:00
parent 2aa1a70225
commit 6377356940
21 changed files with 70 additions and 51 deletions

View File

@ -53,7 +53,7 @@ case "$1" in
echo -n "$FULLNAME server is stopped"
echo
fi
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$name
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$name
;;
status)
if [ -f $pidfile ]

View File

@ -424,8 +424,8 @@ AC_ARG_WITH(system-editline,
READLINE=edit # builtin default
saveLIBS=$LIBS
if test "$STD_EDITLINE" = "true"; then
AC_CHECK_LIB(edit, readline, READLINE=edit,
AC_CHECK_LIB(editline, readline, READLINE=editline,
AC_CHECK_LIB(edit, readline, READLINE=edit,
AC_CHECK_LIB(editline, readline, READLINE=editline,
AC_CHECK_LIB(readline, readline, READLINE=readline, STD_EDITLINE=false)))
fi
if test "$STD_EDITLINE" = "true"; then
@ -802,8 +802,8 @@ case "$PLATFORM" in
dnl MOD: Check for /proc/self/exe mainly used on linux systems
dnl this is used to determine path to executable file.
AC_CHECK_FILES(/proc/self/exe)
;;
FREEBSD|GENTOOFREEBSD)
dnl the AC_CHECK_TYPES for socklen_t doesn't include sys/socket.h
dnl so test for socklen_t with sys/socket.h included

View File

@ -475,7 +475,7 @@ int alice(Firebird::UtilSvc* uSvc)
}
if (!flags || !(flags & ~(sw_user | sw_password | sw_fetch_password |
sw_trusted_auth | sw_trusted_svc | sw_trusted_role)))
sw_trusted_auth | sw_trusted_svc | sw_trusted_role)))
{
if (!help && !uSvc->isService())
{

View File

@ -28,4 +28,3 @@ int EXE_action(const TEXT*, const SINT64);
int EXE_two_phase(const TEXT*, const SINT64);
#endif // ALICE_EXE_PROTO_H

View File

@ -863,5 +863,3 @@ static bool reconnect(FB_API_HANDLE handle, SLONG number, const TEXT* name, SINT
return false;
}

View File

@ -121,14 +121,14 @@ ClumpletReader::ClumpletReader(MemoryPool& pool, Kind k, const UCHAR* buffer, si
rewind(); // this will set cur_offset and spbState
}
const UCHAR* ClumpletReader::getBuffer() const
{
return static_buffer;
const UCHAR* ClumpletReader::getBuffer() const
{
return static_buffer;
}
const UCHAR* ClumpletReader::getBufferEnd() const
{
return static_buffer_end;
const UCHAR* ClumpletReader::getBufferEnd() const
{
return static_buffer_end;
}
void ClumpletReader::usage_mistake(const char* what) const

View File

@ -50,14 +50,14 @@ ClumpletWriter::ClumpletWriter(MemoryPool& given_pool, Kind k, size_t limit, UCH
rewind();
}
const UCHAR* ClumpletWriter::getBuffer() const
{
return dynamic_buffer.begin();
const UCHAR* ClumpletWriter::getBuffer() const
{
return dynamic_buffer.begin();
}
const UCHAR* ClumpletWriter::getBufferEnd() const
{
return dynamic_buffer.end();
const UCHAR* ClumpletWriter::getBufferEnd() const
{
return dynamic_buffer.end();
}
void ClumpletWriter::initNewBuffer(UCHAR tag)

View File

@ -151,7 +151,7 @@ private:
// have to use the Solaris FPE routines.
static void maskAll() throw()
{
fpsetmask( ~(FP_X_OFL | FP_X_INV | FP_X_UFL | FP_X_DZ | FP_X_IMP));
fpsetmask(~(FP_X_OFL | FP_X_INV | FP_X_UFL | FP_X_DZ | FP_X_IMP));
}
private:
@ -164,7 +164,7 @@ private:
{
fp_except saved;
saved = fpgetmask();
fpsetmask( ~(FP_X_OFL | FP_X_INV | FP_X_UFL | FP_X_DZ | FP_X_IMP));
fpsetmask(~(FP_X_OFL | FP_X_INV | FP_X_UFL | FP_X_DZ | FP_X_IMP));
clean = fpgetmask();
fpsetmask(saved);
}
@ -187,8 +187,8 @@ private:
void restoreMask() throw()
{
fpsetsticky (0); // clear exception sticky flags
fpsetmask (savedMask);
fpsetsticky(0); // clear exception sticky flags
fpsetmask(savedMask);
}
#else

View File

@ -329,9 +329,11 @@ private:
// No GNU CC implementation on Solaris 9 is planned!
extern "C"
{
extern int fetch_and_add_il(volatile unsigned int *word_addr, int value);
extern boolean_t compare_and_swap_il(volatile unsigned int *word_addr, unsigned int *old_val_addr, unsigned int new_val);
extern int fetch_and_add_il(volatile unsigned int* word_addr, int value);
extern boolean_t compare_and_swap_il(volatile unsigned int* word_addr,
unsigned int* old_val_addr, unsigned int new_val);
}
namespace Firebird {
class AtomicCounter

View File

@ -309,7 +309,7 @@ ISC_STATUS LongJump::stuff_exception(ISC_STATUS* const status_vector, StringsBuf
return status_vector[1];
}
const char* LongJump::what() const throw()
const char* LongJump::what() const throw()
{
return "Firebird::LongJump";
}
@ -417,4 +417,3 @@ ISC_STATUS stuff_exception(ISC_STATUS *status_vector, const Firebird::Exception&
}
} // namespace Firebird

View File

@ -35,4 +35,3 @@ inline void CME_rse(gpre_nod* node, gpre_req* request)
}
#endif // GPRE_CME_PROTO_H

View File

@ -208,4 +208,3 @@ ISC_STATUS stuff_exception(ISC_STATUS *status_vector, const Firebird::Exception&
#endif // FB_EXCEPTION_H

View File

@ -1172,11 +1172,13 @@ SSHORT ISQL_get_field_length(const TEXT* field_name)
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return 0;
}
}
SSHORT l = 0;
FOR FLD IN RDB$FIELDS WITH
@ -1217,11 +1219,13 @@ void ISQL_get_character_sets(SSHORT char_set_id, SSHORT collation, bool collate_
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return;
}
}
//if (collation) {
if (collation || collate_only)
@ -1320,11 +1324,13 @@ void ISQL_get_default_source(const TEXT* rel_name,
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return;
}
}
if (rel_name)
{
@ -1385,11 +1391,13 @@ SLONG ISQL_get_index_segments(TEXT* segs,
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return 0;
}
}
TEXT* const segs_end = segs + buf_size - 1;
// Query to get column names
@ -1473,11 +1481,13 @@ bool ISQL_get_base_column_null_flag(const TEXT* view_name,
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return false;
}
}
/*
Using view_name and view_context get the relation name from
@ -1545,11 +1555,13 @@ bool ISQL_get_null_flag(const TEXT* rel_name,
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return false;
}
}
if (rel_name)
{
@ -1575,8 +1587,10 @@ bool ISQL_get_null_flag(const TEXT* rel_name,
null_flag = false;
}
else
{
null_flag = ISQL_get_base_column_null_flag (rel_name,
RFR.RDB$VIEW_CONTEXT, RFR.RDB$BASE_FIELD);
RFR.RDB$VIEW_CONTEXT, RFR.RDB$BASE_FIELD);
}
}
END_FOR
@ -1682,11 +1696,13 @@ bool ISQL_is_domain(const TEXT* field_name)
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return false;
}
}
FOR FLD IN RDB$FIELDS WITH
FLD.RDB$FIELD_NAME EQ field_name
@ -1911,19 +1927,23 @@ static processing_state add_row(TEXT* tabname)
// There may have been a commit transaction before we got here
if (!M__trans)
{
if (isc_start_transaction(isc_status, &M__trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return FAIL;
}
}
// Start default transaction for prepare
if (!D__trans)
{
if (isc_start_transaction(isc_status, &D__trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
return FAIL;
}
}
chop_at(tabname, QUOTEDLENGTH);
if (tabname[0] != DBL_QUOTE)
@ -4738,6 +4758,7 @@ static processing_state frontend(const TEXT* statement)
case FrontOptions::show:
// Transaction for all frontend commands
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
@ -4745,6 +4766,8 @@ static processing_state frontend(const TEXT* statement)
frontend_free_parms(parms, lparms, parm_defaults);
return FAIL;
}
}
ret = SHOW_metadata(parms, lparms);
if (gds_trans)
commit_trans(&gds_trans);
@ -4752,6 +4775,7 @@ static processing_state frontend(const TEXT* statement)
case FrontOptions::add:
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
@ -4759,6 +4783,8 @@ static processing_state frontend(const TEXT* statement)
frontend_free_parms(parms, lparms, parm_defaults);
return FAIL;
}
}
ret = add_row(lparms[1]);
if (gds_trans)
commit_trans(&gds_trans);
@ -4766,6 +4792,7 @@ static processing_state frontend(const TEXT* statement)
case FrontOptions::copy:
if (DB && !gds_trans)
{
if (isc_start_transaction(isc_status, &gds_trans, 1, &DB, 0, NULL))
{
ISQL_errmsg(isc_status);
@ -4773,6 +4800,8 @@ static processing_state frontend(const TEXT* statement)
frontend_free_parms(parms, lparms, parm_defaults);
return FAIL;
}
}
ret = copy_table(lparms[1], lparms[2], lparms[3]);
if (gds_trans)
commit_trans(&gds_trans);
@ -5148,7 +5177,7 @@ static processing_state frontend_set(const char* cmd, const char* const* parms,
case SetOptions::planonly:
ret = do_set_command (parms[2], &Planonly);
if ( Planonly && !Plan )
if (Planonly && !Plan)
{
// turn on plan
ret = do_set_command ("ON", &Plan);
@ -6347,7 +6376,8 @@ static bool isyesno(const TEXT* buffer)
**********************************************/
if (!have_trans)
{ // get the translation if we don't have it already
{
// get the translation if we don't have it already
ISQL_msg_get(YES_ANS, sizeof(yesword), yesword);
have_trans = true;
}

View File

@ -393,4 +393,3 @@ const char DBL_QUOTE = '\042';
const char SINGLE_QUOTE = '\'';
#endif // ISQL_ISQL_H

View File

@ -1077,8 +1077,8 @@ void SHOW_print_metadata_text_blob(FILE* fp, ISC_QUAD* blobid, bool escape_squot
while (blob.getSegment(sizeof(buffer) - 1, buffer, length))
{
// ASF: In Windows, \n characters are printed as \r\n in text mode.
// If the original string is \r\n, it's printed as \r\r\n, resulting
// in mixed/wrong line endings. So here, we're filtering any \r just
// If the original string has \r\n, they're printed as \r\r\n, resulting
// in mixed/wrong line endings. So here, we filter any \r present just
// before \n.
bool prevEndedWithCr = endedWithCr;
@ -4643,7 +4643,6 @@ static processing_state show_trigger(const SCHAR* object, bool show_source, bool
if (first && !has_dbtrig)
return OBJECT_NOT_FOUND;
return (SKIP);
}

View File

@ -1416,8 +1416,7 @@ blb* BLB_open2(thread_db* tdbb,
if (filter_required)
{
BlobControl* control = 0;
BLF_open_blob(tdbb, transaction, &control, blob_id, bpb_length, bpb,
blob_filter, filter);
BLF_open_blob(tdbb, transaction, &control, blob_id, bpb_length, bpb, blob_filter, filter);
blob->blb_filter = control;
blob->blb_max_segment = control->ctl_max_segment;
blob->blb_count = control->ctl_number_segments;
@ -1930,7 +1929,7 @@ static ISC_STATUS blob_filter(USHORT action,
}
#endif
blb* blob = 0;
blb* blob = NULL;
switch (action)
{

View File

@ -2923,7 +2923,7 @@ int ISC_mutex_init(struct mtx* mutex)
if (state
#if defined(HAVE_PTHREAD_MUTEXATTR_SETPROTOCOL) || defined(USE_ROBUST_MUTEX)
&& (state != ENOTSUP || bugFlag)
&& (state != ENOTSUP || bugFlag)
#endif
)
{

View File

@ -48,7 +48,7 @@ static bool get_sql_code(SSHORT *);
static bool get_sql_subclass(char*);
static bool store_sql_msg();
static bool translate(const UCHAR*, UCHAR*, SSHORT);
static bool get_symbol( char*);
static bool get_symbol(char*);
const int FAC_SQL_POSITIVE = 14;
const int FAC_SQL_NEGATIVE = 13;

View File

@ -44,11 +44,9 @@ const int COLUMN_WIDTH = 20;
const int RIGHT_MARGIN = 70;
#ifdef UNIX
const char* const TARGET = "help/help.fdb";
#endif
#if (defined WIN_NT)
const char* const TARGET = "help\\help.fdb";
const char* const TARGET = "help/help.fdb";
#elif defined(WIN_NT)
const char* const TARGET = "help\\help.fdb";
#endif
DATABASE HELP_DB = STATIC "help.fdb" RUNTIME target;
@ -352,4 +350,3 @@ static const TEXT* strip( const TEXT* string)
return p;
}

View File

@ -30,8 +30,8 @@ const int APP_VSIZE = 150;
/* This is the title used by the hidden msgs window in the engine.
Both fbclient.dll and fbserver.exe should use the same. */
static const char* const APP_NAME = "Firebird Server";
static const char* const APP_LABEL = "Firebird Server";
static const char* const APP_NAME = "Firebird Server";
static const char* const APP_LABEL = "Firebird Server";
#define ON_NOTIFYICON WM_USER + 2

View File

@ -30,4 +30,3 @@ static const char* const REG_KEY_ROOT_PRODUCT = "SOFTWARE\\Firebird Project\\Fir
static const char* const REG_KEY_ROOT_INSTANCES = "SOFTWARE\\Firebird Project\\Firebird Server\\Instances";
#endif // REGISTRY_DEFINES_H