Fixes that make Haiku build with gcc 4. Mainly out of the following
categories: * Missing includes (like <stdlib.h> and <string.h>). * Linking against $(TARGET_LIBSTDC++) instead of libstdc++.r4.so. * Local variables shadowing parameters. * Default parameters in function definitions (as opposed to function declarations). * All C++ stuff (nothrow, map, set, vector, min, max,...) must be imported explicitly from the std:: namespace now. * "new (sometype)[...]" must read "new sometype[...]", even if sometype is something like "const char *". * __FUNCTION__ is no longer a string literal (but a string expression), i.e. 'printf(__FUNCTION__ ": ...\n")' is invalid code. * A type cast results in a non-lvalue. E.g. "(char *)buffer += bytes" is an invalid expression. * "friend class SomeClass" only works when SomeClass is known before. Otherwise the an inner class with that name is considered as friend. gcc 4 is much pickier about scopes. * gcc 4 is generally stricter with respect to type conversions in C. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14878 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
+21
-21
@@ -80,27 +80,27 @@
|
||||
|
||||
/* cpp kit */
|
||||
|
||||
/* -- <typeinfo> */
|
||||
class _IMPEXP_ROOT bad_cast;
|
||||
class _IMPEXP_ROOT bad_typeid;
|
||||
class _IMPEXP_ROOT type_info;
|
||||
|
||||
/* -- <exception> */
|
||||
class _IMPEXP_ROOT exception;
|
||||
class _IMPEXP_ROOT bad_exception;
|
||||
|
||||
/* -- <new.h> */
|
||||
class _IMPEXP_ROOT bad_alloc;
|
||||
|
||||
/* -- <mexcept.h> */
|
||||
class _IMPEXP_ROOT logic_error;
|
||||
class _IMPEXP_ROOT domain_error;
|
||||
class _IMPEXP_ROOT invalid_argument;
|
||||
class _IMPEXP_ROOT length_error;
|
||||
class _IMPEXP_ROOT out_of_range;
|
||||
class _IMPEXP_ROOT runtime_error;
|
||||
class _IMPEXP_ROOT range_error;
|
||||
class _IMPEXP_ROOT overflow_error;
|
||||
// /* -- <typeinfo> */
|
||||
// class _IMPEXP_ROOT bad_cast;
|
||||
// class _IMPEXP_ROOT bad_typeid;
|
||||
// class _IMPEXP_ROOT type_info;
|
||||
//
|
||||
// /* -- <exception> */
|
||||
// class _IMPEXP_ROOT exception;
|
||||
// class _IMPEXP_ROOT bad_exception;
|
||||
//
|
||||
// /* -- <new.h> */
|
||||
// class _IMPEXP_ROOT bad_alloc;
|
||||
//
|
||||
// /* -- <mexcept.h> */
|
||||
// class _IMPEXP_ROOT logic_error;
|
||||
// class _IMPEXP_ROOT domain_error;
|
||||
// class _IMPEXP_ROOT invalid_argument;
|
||||
// class _IMPEXP_ROOT length_error;
|
||||
// class _IMPEXP_ROOT out_of_range;
|
||||
// class _IMPEXP_ROOT runtime_error;
|
||||
// class _IMPEXP_ROOT range_error;
|
||||
// class _IMPEXP_ROOT overflow_error;
|
||||
|
||||
/* support kit */
|
||||
class _IMPEXP_BE BArchivable;
|
||||
|
||||
@@ -9,11 +9,11 @@
|
||||
#ifndef _MESSAGE_H
|
||||
#define _MESSAGE_H
|
||||
|
||||
#include <BeBuild.h>
|
||||
#include <OS.h>
|
||||
#include <Rect.h>
|
||||
#include <DataIO.h>
|
||||
#include <Flattenable.h>
|
||||
#include <Messenger.h>
|
||||
#include <OS.h>
|
||||
#include <Rect.h>
|
||||
|
||||
// for convenience
|
||||
#include <AppDefs.h>
|
||||
|
||||
@@ -77,12 +77,13 @@ public:
|
||||
size_t inAttributeCount);
|
||||
|
||||
void * operator new(size_t size);
|
||||
void * operator new(size_t size, const nothrow_t &) throw();
|
||||
void * operator new(size_t size,
|
||||
const std::nothrow_t &) throw();
|
||||
void operator delete(void * ptr);
|
||||
#if !__MWERKS__
|
||||
// there's a bug in MWCC under R4.1 and earlier
|
||||
void operator delete(void * ptr,
|
||||
const nothrow_t &) throw();
|
||||
const std::nothrow_t &) throw();
|
||||
#endif
|
||||
|
||||
static status_t SetMemoryPoolSize(size_t in_poolSize);
|
||||
|
||||
@@ -57,6 +57,12 @@ operator==(const pattern& a, const pattern& b)
|
||||
return (*(uint64*)a.data == *(uint64*)b.data);
|
||||
}
|
||||
|
||||
inline bool
|
||||
operator!=(const pattern& a, const pattern& b)
|
||||
{
|
||||
return !(a == b);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
extern _IMPEXP_BE const pattern B_SOLID_HIGH;
|
||||
|
||||
@@ -15,6 +15,7 @@ class BEntry;
|
||||
struct entry_ref;
|
||||
|
||||
class _rep_data_;
|
||||
class _TContainerViewFilter_;
|
||||
|
||||
class BShelf : public BHandler {
|
||||
public:
|
||||
|
||||
@@ -356,7 +356,7 @@ extern void debugger(const char *message);
|
||||
|
||||
to re-enable the default debugger pass a zero.
|
||||
*/
|
||||
extern const int disable_debugger(int state);
|
||||
extern int disable_debugger(int state);
|
||||
|
||||
// TODO: Remove. Temporary debug helper.
|
||||
extern void debug_printf(const char *format, ...)
|
||||
|
||||
@@ -236,14 +236,14 @@ virtual status_t HandleMessage(
|
||||
size_t size);
|
||||
void * operator new(
|
||||
size_t size,
|
||||
const nothrow_t &) throw();
|
||||
const std::nothrow_t &) throw();
|
||||
void operator delete(
|
||||
void * ptr);
|
||||
#if !__MWERKS__
|
||||
// there's a bug in MWCC under R4.1 and earlier
|
||||
void operator delete(
|
||||
void * ptr,
|
||||
const nothrow_t &) throw();
|
||||
const std::nothrow_t &) throw();
|
||||
#endif
|
||||
|
||||
protected:
|
||||
|
||||
@@ -12,7 +12,9 @@
|
||||
|
||||
|
||||
class BSound;
|
||||
class sound_error : public exception {
|
||||
class _SoundPlayNode;
|
||||
|
||||
class sound_error : public std::exception {
|
||||
const char * m_str_const;
|
||||
public:
|
||||
sound_error(const char * str);
|
||||
|
||||
@@ -156,7 +156,7 @@ int sigismember(const sigset_t *set, int signo);
|
||||
|
||||
const char *strsignal(int sig);
|
||||
|
||||
const void set_signal_stack(void *ptr, size_t size);
|
||||
void set_signal_stack(void *ptr, size_t size);
|
||||
int sigaltstack(const stack_t *ss, stack_t *oss); /* XXXdbg */
|
||||
|
||||
extern inline int
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
#include <MessageField.h>
|
||||
// Standard Includes -----------------------------------------------------------
|
||||
#include <map>
|
||||
#include <new>
|
||||
#include <stdio.h>
|
||||
#include <string>
|
||||
|
||||
@@ -52,6 +53,8 @@
|
||||
|
||||
enum { B_FLATTENABLE_TYPE = 'FLAT' };
|
||||
|
||||
using namespace std;
|
||||
|
||||
namespace BPrivate {
|
||||
|
||||
class BMessageBody
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
#define MESSAGEFIELD_H
|
||||
|
||||
// Standard Includes -----------------------------------------------------------
|
||||
#include <new>
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <vector>
|
||||
@@ -58,6 +59,8 @@
|
||||
|
||||
#define MSG_LAST_ENTRY 0x0
|
||||
|
||||
using namespace std;
|
||||
|
||||
// Globals ---------------------------------------------------------------------
|
||||
namespace BPrivate {
|
||||
|
||||
|
||||
@@ -73,36 +73,36 @@
|
||||
#error you need to define DEBUG_MSG_PREFIX with the module name
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif
|
||||
|
||||
@@ -784,7 +784,7 @@
|
||||
#define NV_REG32(r_) ((vuint32 *)regs)[(r_) >> 2]
|
||||
|
||||
/* read and write to PCI config space */
|
||||
#define CFGR(A) (nv_pci_access.offset=NVCFG_##A, ioctl(fd,NV_GET_PCI, &nv_pci_access,sizeof(nv_pci_access)), nv_pci_access.value)
|
||||
#define CFGR(A) (*(nv_pci_access.offset=NVCFG_##A, ioctl(fd,NV_GET_PCI, &nv_pci_access,sizeof(nv_pci_access)), &nv_pci_access.value))
|
||||
#define CFGW(A,B) (nv_pci_access.offset=NVCFG_##A, nv_pci_access.value = B, ioctl(fd,NV_SET_PCI,&nv_pci_access,sizeof(nv_pci_access)))
|
||||
|
||||
/* read and write from ISA I/O space */
|
||||
|
||||
@@ -10,6 +10,12 @@
|
||||
|
||||
#include <util/AutoLock.h>
|
||||
|
||||
// instantiations
|
||||
#include <KDiskDevice.h>
|
||||
#include <KDiskDeviceManager.h>
|
||||
#include <KDiskSystem.h>
|
||||
#include <KPartition.h>
|
||||
|
||||
namespace BPrivate {
|
||||
namespace DiskDevice {
|
||||
|
||||
|
||||
@@ -93,7 +93,7 @@ class List {
|
||||
}
|
||||
|
||||
private:
|
||||
friend class IteratorType;
|
||||
friend class DoublyLinked::Iterator<Item, LinkMember>;
|
||||
Link fLink;
|
||||
};
|
||||
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <OS.h>
|
||||
#include <TypeConstants.h>
|
||||
|
||||
class BMessage;
|
||||
|
||||
namespace BPrivate {
|
||||
|
||||
class KMessageField;
|
||||
@@ -100,7 +102,7 @@ public:
|
||||
|
||||
private:
|
||||
friend class KMessageField;
|
||||
friend class BMessage; // not so nice, but makes things easier
|
||||
friend class ::BMessage; // not so nice, but makes things easier
|
||||
|
||||
struct Header {
|
||||
uint32 magic;
|
||||
|
||||
@@ -127,8 +127,11 @@ private:
|
||||
int32 _FindInsertionIndex(const Key &key, bool &exists) const;
|
||||
|
||||
private:
|
||||
friend class Entry;
|
||||
friend class ConstEntry;
|
||||
// friend class Entry;
|
||||
// friend class ConstEntry;
|
||||
friend class VectorMapEntry<KeyReference, Value, _Entry, Class>;
|
||||
friend class VectorMapEntry<KeyReference, const Value, const _Entry,
|
||||
const Class>;
|
||||
|
||||
ElementVector fElements;
|
||||
EntryStrategy fEntryStrategy;
|
||||
|
||||
@@ -6,6 +6,8 @@
|
||||
#ifndef _DATA_EXCHANGE_H
|
||||
#define _DATA_EXCHANGE_H
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include <MediaFormats.h>
|
||||
#include <MediaNode.h>
|
||||
#include <MediaAddOn.h>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
struct sockaddr;
|
||||
|
||||
#define NET_STACK_DRIVER_DEV "net/stack"
|
||||
#define NET_STACK_DRIVER_PATH "/dev/" ## NET_STACK_DRIVER_DEV
|
||||
#define NET_STACK_DRIVER_PATH "/dev/" NET_STACK_DRIVER_DEV
|
||||
|
||||
enum {
|
||||
// Paranoia mode: be far away of B_DEVICE_OP_CODES_END opcodes!!!
|
||||
|
||||
@@ -7,6 +7,8 @@
|
||||
* It's used by Pulse, AboutHaiku, and sysinfo.
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <OS.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -561,6 +561,7 @@ void Radeon_CalcImpacTVRegisters(
|
||||
values->tv_dac_cntl |= RADEON_TV_DAC_CNTL_STD_PAL;
|
||||
break;
|
||||
default:
|
||||
;
|
||||
}
|
||||
|
||||
// enable composite or S-Video DAC
|
||||
@@ -630,6 +631,7 @@ void Radeon_CalcImpacTVRegisters(
|
||||
|
||||
default:
|
||||
// there are many formats missing, sigh...
|
||||
;
|
||||
}
|
||||
|
||||
// RE:
|
||||
|
||||
@@ -266,5 +266,6 @@ void Radeon_DetectTVOut(
|
||||
break; }
|
||||
default:
|
||||
// for internal encoder, we don't have to look farther - it must be there
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,71 +34,71 @@ get_accelerant_hook(uint32 feature, void *data)
|
||||
switch (feature) {
|
||||
/* general */
|
||||
case B_INIT_ACCELERANT:
|
||||
return vesa_init_accelerant;
|
||||
return (void*)vesa_init_accelerant;
|
||||
case B_UNINIT_ACCELERANT:
|
||||
return vesa_uninit_accelerant;
|
||||
return (void*)vesa_uninit_accelerant;
|
||||
case B_CLONE_ACCELERANT:
|
||||
return vesa_clone_accelerant;
|
||||
return (void*)vesa_clone_accelerant;
|
||||
case B_ACCELERANT_CLONE_INFO_SIZE:
|
||||
return vesa_accelerant_clone_info_size;
|
||||
return (void*)vesa_accelerant_clone_info_size;
|
||||
case B_GET_ACCELERANT_CLONE_INFO:
|
||||
return vesa_get_accelerant_clone_info;
|
||||
return (void*)vesa_get_accelerant_clone_info;
|
||||
case B_GET_ACCELERANT_DEVICE_INFO:
|
||||
return vesa_get_accelerant_device_info;
|
||||
return (void*)vesa_get_accelerant_device_info;
|
||||
case B_ACCELERANT_RETRACE_SEMAPHORE:
|
||||
return vesa_accelerant_retrace_semaphore;
|
||||
return (void*)vesa_accelerant_retrace_semaphore;
|
||||
|
||||
/* mode configuration */
|
||||
case B_ACCELERANT_MODE_COUNT:
|
||||
return vesa_accelerant_mode_count;
|
||||
return (void*)vesa_accelerant_mode_count;
|
||||
case B_GET_MODE_LIST:
|
||||
return vesa_get_mode_list;
|
||||
return (void*)vesa_get_mode_list;
|
||||
case B_PROPOSE_DISPLAY_MODE:
|
||||
return vesa_propose_display_mode;
|
||||
return (void*)vesa_propose_display_mode;
|
||||
case B_SET_DISPLAY_MODE:
|
||||
return vesa_set_display_mode;
|
||||
return (void*)vesa_set_display_mode;
|
||||
case B_GET_DISPLAY_MODE:
|
||||
return vesa_get_display_mode;
|
||||
return (void*)vesa_get_display_mode;
|
||||
case B_GET_FRAME_BUFFER_CONFIG:
|
||||
return vesa_get_frame_buffer_config;
|
||||
return (void*)vesa_get_frame_buffer_config;
|
||||
case B_GET_PIXEL_CLOCK_LIMITS:
|
||||
return vesa_get_pixel_clock_limits;
|
||||
return (void*)vesa_get_pixel_clock_limits;
|
||||
case B_MOVE_DISPLAY:
|
||||
return vesa_move_display;
|
||||
return (void*)vesa_move_display;
|
||||
case B_SET_INDEXED_COLORS:
|
||||
return vesa_set_indexed_colors;
|
||||
return (void*)vesa_set_indexed_colors;
|
||||
case B_GET_TIMING_CONSTRAINTS:
|
||||
return vesa_get_timing_constraints;
|
||||
return (void*)vesa_get_timing_constraints;
|
||||
|
||||
/* DPMS */
|
||||
case B_DPMS_CAPABILITIES:
|
||||
return vesa_dpms_capabilities;
|
||||
return (void*)vesa_dpms_capabilities;
|
||||
case B_DPMS_MODE:
|
||||
return vesa_dpms_mode;
|
||||
return (void*)vesa_dpms_mode;
|
||||
case B_SET_DPMS_MODE:
|
||||
return vesa_set_dpms_mode;
|
||||
return (void*)vesa_set_dpms_mode;
|
||||
|
||||
/* cursor managment */
|
||||
case B_SET_CURSOR_SHAPE:
|
||||
return vesa_set_cursor_shape;
|
||||
return (void*)vesa_set_cursor_shape;
|
||||
case B_MOVE_CURSOR:
|
||||
return vesa_move_cursor;
|
||||
return (void*)vesa_move_cursor;
|
||||
case B_SHOW_CURSOR:
|
||||
return vesa_show_cursor;
|
||||
return (void*)vesa_show_cursor;
|
||||
|
||||
/* engine/synchronization */
|
||||
case B_ACCELERANT_ENGINE_COUNT:
|
||||
return vesa_accelerant_engine_count;
|
||||
return (void*)vesa_accelerant_engine_count;
|
||||
case B_ACQUIRE_ENGINE:
|
||||
return vesa_acquire_engine;
|
||||
return (void*)vesa_acquire_engine;
|
||||
case B_RELEASE_ENGINE:
|
||||
return vesa_release_engine;
|
||||
return (void*)vesa_release_engine;
|
||||
case B_WAIT_ENGINE_IDLE:
|
||||
return vesa_wait_engine_idle;
|
||||
return (void*)vesa_wait_engine_idle;
|
||||
case B_GET_SYNC_TOKEN:
|
||||
return vesa_get_sync_token;
|
||||
return (void*)vesa_get_sync_token;
|
||||
case B_SYNC_TO_TOKEN:
|
||||
return vesa_sync_to_token;
|
||||
return (void*)vesa_sync_to_token;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include "accelerant_protos.h"
|
||||
#include "accelerant.h"
|
||||
|
||||
@@ -19,7 +19,7 @@ static pci_module_info *gPCI = NULL;
|
||||
|
||||
#define B_CONFIG_MANAGER_FOR_BUS_MODULE_NAME "bus_managers/config_manager/bus/v1"
|
||||
|
||||
#define FUNCTION(x...) dprintf(__FUNCTION__ x)
|
||||
#define FUNCTION(x, y...) dprintf("%s" x, __FUNCTION__, y)
|
||||
#define TRACE(x) dprintf x
|
||||
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ copy_sg_data(scsi_ccb *request, uint offset, uint allocation_length,
|
||||
|
||||
unmap_mainmemory(virt_addr);
|
||||
|
||||
(char *)buffer += bytes;
|
||||
buffer = (char *)buffer + bytes;
|
||||
size -= bytes;
|
||||
offset = 0;
|
||||
}
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 4
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -271,8 +271,6 @@ scsi_start_emulation(scsi_ccb *request)
|
||||
|
||||
case SCSI_OP_MODE_SELECT_6:
|
||||
return scsi_start_mode_select_6(request);
|
||||
|
||||
default:
|
||||
}
|
||||
|
||||
return true;
|
||||
@@ -506,7 +504,7 @@ copy_sg_data(scsi_ccb *request, uint offset, uint allocation_length,
|
||||
|
||||
unmap_mainmemory((void *)virt_addr);
|
||||
|
||||
(char *)buffer += bytes;
|
||||
buffer = (char *)buffer + bytes;
|
||||
size -= bytes;
|
||||
offset = 0;
|
||||
}
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 1
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 3
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#define VERSION_DEBUG ""
|
||||
#endif
|
||||
|
||||
#define VERSION "Version " VERSION_NUMBER VERSION_DEBUG ", Copyright (c) 2002-2005 Marcus Overhagen, compiled on " ## __DATE__ ## " " ## __TIME__
|
||||
#define VERSION "Version " VERSION_NUMBER VERSION_DEBUG ", Copyright (c) 2002-2005 Marcus Overhagen, compiled on " __DATE__ " " __TIME__
|
||||
#define DRIVER_NAME "ich_ac97"
|
||||
|
||||
#define BUFFER_SIZE 2048
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 1
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 3
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -124,6 +124,7 @@ int32 pci_getlist(pci_info *info[], int32 maxEntries)
|
||||
j++;
|
||||
}
|
||||
next_entry:
|
||||
; // gcc 4 doesn't like labels at the end of a compound statement
|
||||
}
|
||||
|
||||
info[entries] = NULL;
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
** This file may be used under the terms of the OpenBeOS License.
|
||||
*/
|
||||
|
||||
#include <null.h>
|
||||
|
||||
/** The Link class you want to use with the Chain class needs to have
|
||||
* a "fNext" member which is accessable from within the Chain class.
|
||||
|
||||
@@ -1764,8 +1764,11 @@ Inode::ShrinkStream(Transaction &transaction, off_t size)
|
||||
status_t status;
|
||||
|
||||
if (data->MaxDoubleIndirectRange() > size) {
|
||||
off_t *maxDoubleIndirect = &data->max_double_indirect_range;
|
||||
// gcc 4 work-around: "error: cannot bind packed field
|
||||
// 'data->data_stream::max_double_indirect_range' to 'off_t&'"
|
||||
status = FreeStaticStreamArray(transaction, 0, data->double_indirect, size,
|
||||
data->MaxIndirectRange(), data->max_double_indirect_range);
|
||||
data->MaxIndirectRange(), *maxDoubleIndirect);
|
||||
if (status < B_OK)
|
||||
return status;
|
||||
|
||||
@@ -1785,8 +1788,11 @@ Inode::ShrinkStream(Transaction &transaction, off_t size)
|
||||
if (array == NULL)
|
||||
break;
|
||||
|
||||
off_t *maxIndirect = &data->max_indirect_range;
|
||||
// gcc 4 work-around: "error: cannot bind packed field
|
||||
// 'data->data_stream::max_indirect_range' to 'off_t&'"
|
||||
if (FreeStreamArray(transaction, array, fVolume->BlockSize() / sizeof(block_run),
|
||||
size, offset, data->max_indirect_range) != B_OK)
|
||||
size, offset, *maxIndirect) != B_OK)
|
||||
return B_IO_ERROR;
|
||||
}
|
||||
if (data->max_direct_range == data->max_indirect_range) {
|
||||
@@ -1797,8 +1803,11 @@ Inode::ShrinkStream(Transaction &transaction, off_t size)
|
||||
}
|
||||
if (data->MaxDirectRange() > size) {
|
||||
off_t offset = 0;
|
||||
off_t *maxDirect = &data->max_indirect_range;
|
||||
// gcc 4 work-around: "error: cannot bind packed field
|
||||
// 'data->data_stream::max_direct_range' to 'off_t&'"
|
||||
status = FreeStreamArray(transaction, data->direct, NUM_DIRECT_BLOCKS,
|
||||
size, offset, data->max_direct_range);
|
||||
size, offset, *maxDirect);
|
||||
if (status < B_OK)
|
||||
return status;
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ struct iovec block_io_buffer_vec[1];
|
||||
void *block_io_buffer_phys;
|
||||
char *block_io_buffer;
|
||||
phys_vecs block_io_buffer_phys_vec;
|
||||
static area_id block_io_buffer_area;
|
||||
area_id block_io_buffer_area;
|
||||
|
||||
locked_pool_interface *locked_pool;
|
||||
device_manager_info *pnp;
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 2
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 4
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -54,36 +54,36 @@
|
||||
# define debug_level_error 2
|
||||
#endif
|
||||
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX __FUNCTION__ ": "
|
||||
#define FUNC_NAME DEBUG_MSG_PREFIX, __FUNCTION__
|
||||
|
||||
#define SHOW_FLOW(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_FLOW0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_flow && seriousness <= DEBUG_MAX_LEVEL_FLOW ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_INFO0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_info && seriousness <= DEBUG_MAX_LEVEL_INFO ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR(seriousness, format, param...) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME, param ); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#define SHOW_ERROR0(seriousness, format) \
|
||||
do { if( seriousness <= debug_level_error && seriousness <= DEBUG_MAX_LEVEL_ERROR ) { \
|
||||
dprintf( "%s"##format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
dprintf( "%s%s: "format"\n", FUNC_NAME); DEBUG_WAIT_ERROR \
|
||||
}} while( 0 )
|
||||
|
||||
#endif /* _BENAPHORE_H */
|
||||
|
||||
@@ -208,7 +208,7 @@ PPPManager::Control(ifnet *ifp, ulong cmd, caddr_t data)
|
||||
|
||||
ppp_interface_id
|
||||
PPPManager::CreateInterface(const driver_settings *settings,
|
||||
ppp_interface_id parentID = PPP_UNDEFINED_INTERFACE_ID)
|
||||
ppp_interface_id parentID)
|
||||
{
|
||||
return _CreateInterface(NULL, settings, parentID);
|
||||
}
|
||||
@@ -216,7 +216,7 @@ PPPManager::CreateInterface(const driver_settings *settings,
|
||||
|
||||
ppp_interface_id
|
||||
PPPManager::CreateInterfaceWithName(const char *name,
|
||||
ppp_interface_id parentID = PPP_UNDEFINED_INTERFACE_ID)
|
||||
ppp_interface_id parentID)
|
||||
{
|
||||
if(!name)
|
||||
return PPP_UNDEFINED_INTERFACE_ID;
|
||||
@@ -531,7 +531,7 @@ PPPManager::ControlInterface(ppp_interface_id ID, uint32 op, void *data, size_t
|
||||
|
||||
int32
|
||||
PPPManager::GetInterfaces(ppp_interface_id *interfaces, int32 count,
|
||||
ppp_interface_filter filter = PPP_REGISTERED_INTERFACES)
|
||||
ppp_interface_filter filter)
|
||||
{
|
||||
TRACE("PPPManager: GetInterfaces()\n");
|
||||
|
||||
@@ -572,7 +572,7 @@ PPPManager::GetInterfaces(ppp_interface_id *interfaces, int32 count,
|
||||
|
||||
|
||||
int32
|
||||
PPPManager::CountInterfaces(ppp_interface_filter filter = PPP_REGISTERED_INTERFACES)
|
||||
PPPManager::CountInterfaces(ppp_interface_filter filter)
|
||||
{
|
||||
TRACE("PPPManager: CountInterfaces()\n");
|
||||
|
||||
@@ -611,7 +611,7 @@ PPPManager::CountInterfaces(ppp_interface_filter filter = PPP_REGISTERED_INTERFA
|
||||
|
||||
|
||||
ppp_interface_entry*
|
||||
PPPManager::EntryFor(ppp_interface_id ID, int32 *saveIndex = NULL) const
|
||||
PPPManager::EntryFor(ppp_interface_id ID, int32 *saveIndex) const
|
||||
{
|
||||
TRACE("PPPManager: EntryFor(%ld)\n", ID);
|
||||
|
||||
@@ -633,7 +633,7 @@ PPPManager::EntryFor(ppp_interface_id ID, int32 *saveIndex = NULL) const
|
||||
|
||||
|
||||
ppp_interface_entry*
|
||||
PPPManager::EntryFor(ifnet *ifp, int32 *saveIndex = NULL) const
|
||||
PPPManager::EntryFor(ifnet *ifp, int32 *saveIndex) const
|
||||
{
|
||||
if(!ifp)
|
||||
return NULL;
|
||||
@@ -655,7 +655,7 @@ PPPManager::EntryFor(ifnet *ifp, int32 *saveIndex = NULL) const
|
||||
|
||||
|
||||
ppp_interface_entry*
|
||||
PPPManager::EntryFor(const char *name, int32 *saveIndex = NULL) const
|
||||
PPPManager::EntryFor(const char *name, int32 *saveIndex) const
|
||||
{
|
||||
if(!name)
|
||||
return NULL;
|
||||
|
||||
@@ -215,7 +215,7 @@ IPCP::Down()
|
||||
|
||||
|
||||
status_t
|
||||
IPCP::Send(struct mbuf *packet, uint16 protocolNumber = IPCP_PROTOCOL)
|
||||
IPCP::Send(struct mbuf *packet, uint16 protocolNumber)
|
||||
{
|
||||
TRACE("IPCP: Send(0x%X)\n", protocolNumber);
|
||||
|
||||
@@ -1373,7 +1373,7 @@ IPCP::SendTerminateRequest()
|
||||
|
||||
|
||||
bool
|
||||
IPCP::SendTerminateAck(struct mbuf *request = NULL)
|
||||
IPCP::SendTerminateAck(struct mbuf *request)
|
||||
{
|
||||
TRACE("IPCP: SendTerminateAck() state=%d\n", State());
|
||||
|
||||
|
||||
@@ -421,7 +421,7 @@ ModemDevice::ConnectionLost()
|
||||
|
||||
|
||||
status_t
|
||||
ModemDevice::Send(struct mbuf *packet, uint16 protocolNumber = 0)
|
||||
ModemDevice::Send(struct mbuf *packet, uint16 protocolNumber)
|
||||
{
|
||||
#if DEBUG
|
||||
TRACE("ModemDevice: Send()\n");
|
||||
@@ -525,7 +525,7 @@ ModemDevice::DataReceived(uint8 *buffer, uint32 length)
|
||||
|
||||
|
||||
status_t
|
||||
ModemDevice::Receive(struct mbuf *packet, uint16 protocolNumber = 0)
|
||||
ModemDevice::Receive(struct mbuf *packet, uint16 protocolNumber)
|
||||
{
|
||||
// we do not need to lock because only the worker_thread calls this method
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#include <core_funcs.h>
|
||||
|
||||
|
||||
DiscoveryPacket::DiscoveryPacket(uint8 code, uint16 sessionID = 0x0000)
|
||||
DiscoveryPacket::DiscoveryPacket(uint8 code, uint16 sessionID)
|
||||
: fCode(code),
|
||||
fSessionID(sessionID),
|
||||
fInitStatus(B_OK)
|
||||
@@ -16,7 +16,7 @@ DiscoveryPacket::DiscoveryPacket(uint8 code, uint16 sessionID = 0x0000)
|
||||
}
|
||||
|
||||
|
||||
DiscoveryPacket::DiscoveryPacket(struct mbuf *packet, uint32 start = 0)
|
||||
DiscoveryPacket::DiscoveryPacket(struct mbuf *packet, uint32 start)
|
||||
{
|
||||
// decode packet
|
||||
uint8 *data = mtod(packet, uint8*);
|
||||
@@ -55,7 +55,7 @@ DiscoveryPacket::~DiscoveryPacket()
|
||||
|
||||
|
||||
bool
|
||||
DiscoveryPacket::AddTag(uint16 type, const void *data, uint16 length, int32 index = -1)
|
||||
DiscoveryPacket::AddTag(uint16 type, const void *data, uint16 length, int32 index)
|
||||
{
|
||||
pppoe_tag *add = (pppoe_tag*) malloc(length + 4);
|
||||
add->type = type;
|
||||
@@ -117,7 +117,7 @@ DiscoveryPacket::TagWithType(uint16 type) const
|
||||
|
||||
|
||||
struct mbuf*
|
||||
DiscoveryPacket::ToMbuf(uint32 MTU, uint32 reserve = ETHER_HDR_LEN)
|
||||
DiscoveryPacket::ToMbuf(uint32 MTU, uint32 reserve)
|
||||
{
|
||||
struct mbuf *packet = m_gethdr(MT_DATA);
|
||||
packet->m_data += reserve;
|
||||
|
||||
@@ -253,7 +253,7 @@ PPPoEDevice::CountOutputBytes() const
|
||||
|
||||
|
||||
status_t
|
||||
PPPoEDevice::Send(struct mbuf *packet, uint16 protocolNumber = 0)
|
||||
PPPoEDevice::Send(struct mbuf *packet, uint16 protocolNumber)
|
||||
{
|
||||
// Send() is only for PPP packets. PPPoE packets are sent directly to ethernet.
|
||||
|
||||
@@ -313,7 +313,7 @@ PPPoEDevice::Send(struct mbuf *packet, uint16 protocolNumber = 0)
|
||||
|
||||
|
||||
status_t
|
||||
PPPoEDevice::Receive(struct mbuf *packet, uint16 protocolNumber = 0)
|
||||
PPPoEDevice::Receive(struct mbuf *packet, uint16 protocolNumber)
|
||||
{
|
||||
if(!packet)
|
||||
return B_ERROR;
|
||||
|
||||
@@ -92,7 +92,7 @@ KPPPConfigurePacket::SetCode(uint8 code)
|
||||
\sa ppp_configure_item
|
||||
*/
|
||||
bool
|
||||
KPPPConfigurePacket::AddItem(const ppp_configure_item *item, int32 index = -1)
|
||||
KPPPConfigurePacket::AddItem(const ppp_configure_item *item, int32 index)
|
||||
{
|
||||
if(!item || item->length < 2)
|
||||
return false;
|
||||
@@ -167,7 +167,7 @@ KPPPConfigurePacket::ItemWithType(uint8 type) const
|
||||
\return The mbuf structure or \c NULL on error (e.g.: too big for given MRU).
|
||||
*/
|
||||
struct mbuf*
|
||||
KPPPConfigurePacket::ToMbuf(uint32 MRU, uint32 reserve = 0)
|
||||
KPPPConfigurePacket::ToMbuf(uint32 MRU, uint32 reserve)
|
||||
{
|
||||
struct mbuf *packet = m_gethdr(MT_DATA);
|
||||
packet->m_data += reserve;
|
||||
|
||||
@@ -78,7 +78,7 @@ status_t interface_deleter_thread(void *data);
|
||||
*/
|
||||
KPPPInterface::KPPPInterface(const char *name, ppp_interface_entry *entry,
|
||||
ppp_interface_id ID, const driver_settings *settings,
|
||||
KPPPInterface *parent = NULL)
|
||||
KPPPInterface *parent)
|
||||
: KPPPLayer(name, PPP_INTERFACE_LEVEL, 2),
|
||||
fID(ID),
|
||||
fSettings(NULL),
|
||||
@@ -833,7 +833,7 @@ KPPPInterface::ProtocolAt(int32 index) const
|
||||
\return Either the object that was found or \c NULL.
|
||||
*/
|
||||
KPPPProtocol*
|
||||
KPPPInterface::ProtocolFor(uint16 protocolNumber, KPPPProtocol *start = NULL) const
|
||||
KPPPInterface::ProtocolFor(uint16 protocolNumber, KPPPProtocol *start) const
|
||||
{
|
||||
TRACE("KPPPInterface: ProtocolFor(%X)\n", protocolNumber);
|
||||
|
||||
@@ -909,7 +909,7 @@ KPPPInterface::ChildAt(int32 index) const
|
||||
|
||||
//! Enables or disables the auto-reconnect feture.
|
||||
void
|
||||
KPPPInterface::SetAutoReconnect(bool autoReconnect = true)
|
||||
KPPPInterface::SetAutoReconnect(bool autoReconnect)
|
||||
{
|
||||
TRACE("KPPPInterface: SetAutoReconnect(%s)\n", autoReconnect ? "true" : "false");
|
||||
|
||||
@@ -924,7 +924,7 @@ KPPPInterface::SetAutoReconnect(bool autoReconnect = true)
|
||||
|
||||
//! Enables or disables the connect-on-demand feature.
|
||||
void
|
||||
KPPPInterface::SetConnectOnDemand(bool connectOnDemand = true)
|
||||
KPPPInterface::SetConnectOnDemand(bool connectOnDemand)
|
||||
{
|
||||
// All protocols must check if ConnectOnDemand was enabled/disabled after this
|
||||
// interface went down. This is the only situation where a change is relevant.
|
||||
|
||||
@@ -103,7 +103,7 @@ KPPPLCP::OptionHandlerAt(int32 index) const
|
||||
|
||||
//! Returns the option handler that can handle options of a given \a type.
|
||||
KPPPOptionHandler*
|
||||
KPPPLCP::OptionHandlerFor(uint8 type, int32 *start = NULL) const
|
||||
KPPPLCP::OptionHandlerFor(uint8 type, int32 *start) const
|
||||
{
|
||||
// The iteration style in this method is strange C/C++.
|
||||
// Explanation: I use this style because it makes extending all XXXFor
|
||||
@@ -180,7 +180,7 @@ KPPPLCP::LCPExtensionAt(int32 index) const
|
||||
|
||||
//! Returns the LCP extension that can handle LCP packets of a given \a code.
|
||||
KPPPLCPExtension*
|
||||
KPPPLCP::LCPExtensionFor(uint8 code, int32 *start = NULL) const
|
||||
KPPPLCP::LCPExtensionFor(uint8 code, int32 *start) const
|
||||
{
|
||||
// The iteration style in this method is strange C/C++.
|
||||
// Explanation: I use this style because it makes extending all XXXFor
|
||||
@@ -239,7 +239,7 @@ KPPPLCP::Down()
|
||||
|
||||
//! Sends a packet to the target (if there is one) or to the interface.
|
||||
status_t
|
||||
KPPPLCP::Send(struct mbuf *packet, uint16 protocolNumber = PPP_LCP_PROTOCOL)
|
||||
KPPPLCP::Send(struct mbuf *packet, uint16 protocolNumber)
|
||||
{
|
||||
if(Target())
|
||||
return Target()->Send(packet, PPP_LCP_PROTOCOL);
|
||||
|
||||
@@ -41,8 +41,8 @@
|
||||
KPPPProtocol::KPPPProtocol(const char *name, ppp_phase activationPhase,
|
||||
uint16 protocolNumber, ppp_level level, int32 addressFamily,
|
||||
uint32 overhead, KPPPInterface& interface,
|
||||
driver_parameter *settings, int32 flags = PPP_NO_FLAGS,
|
||||
const char *type = NULL, KPPPOptionHandler *optionHandler = NULL)
|
||||
driver_parameter *settings, int32 flags,
|
||||
const char *type, KPPPOptionHandler *optionHandler)
|
||||
: KPPPLayer(name, level, overhead),
|
||||
fActivationPhase(activationPhase),
|
||||
fProtocolNumber(protocolNumber),
|
||||
@@ -156,7 +156,7 @@ KPPPProtocol::StackControl(uint32 op, void *data)
|
||||
A disabled protocol is ignored and Up() is not called!
|
||||
*/
|
||||
void
|
||||
KPPPProtocol::SetEnabled(bool enabled = true)
|
||||
KPPPProtocol::SetEnabled(bool enabled)
|
||||
{
|
||||
fEnabled = enabled;
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ KPPPReportManager::SendReport(thread_id thread, const ppp_report_packet *report)
|
||||
*/
|
||||
void
|
||||
KPPPReportManager::EnableReports(ppp_report_type type, thread_id thread,
|
||||
int32 flags = PPP_NO_FLAGS)
|
||||
int32 flags)
|
||||
{
|
||||
if(thread < 0 || type == PPP_ALL_REPORTS)
|
||||
return;
|
||||
|
||||
@@ -1331,7 +1331,7 @@ KPPPStateMachine::RTAEvent(struct mbuf *packet)
|
||||
// receive unknown code
|
||||
void
|
||||
KPPPStateMachine::RUCEvent(struct mbuf *packet, uint16 protocolNumber,
|
||||
uint8 code = PPP_PROTOCOL_REJECT)
|
||||
uint8 code)
|
||||
{
|
||||
TRACE("KPPPSM: RUCEvent() state=%d phase=%d\n", State(), Phase());
|
||||
|
||||
@@ -1835,7 +1835,7 @@ KPPPStateMachine::SendTerminateRequest()
|
||||
|
||||
|
||||
bool
|
||||
KPPPStateMachine::SendTerminateAck(struct mbuf *request = NULL)
|
||||
KPPPStateMachine::SendTerminateAck(struct mbuf *request)
|
||||
{
|
||||
TRACE("KPPPSM: SendTerminateAck() state=%d phase=%d\n", State(), Phase());
|
||||
|
||||
|
||||
@@ -38,9 +38,9 @@ typedef struct ppp_interface_module_info {
|
||||
//!< Exports needed network module functions.
|
||||
|
||||
ppp_interface_id (*CreateInterface)(const driver_settings *settings,
|
||||
ppp_interface_id parentID = PPP_UNDEFINED_INTERFACE_ID);
|
||||
ppp_interface_id parentID);
|
||||
ppp_interface_id (*CreateInterfaceWithName)(const char *name,
|
||||
ppp_interface_id parentID = PPP_UNDEFINED_INTERFACE_ID);
|
||||
ppp_interface_id parentID);
|
||||
bool (*DeleteInterface)(ppp_interface_id ID);
|
||||
// this marks the interface for deletion
|
||||
bool (*RemoveInterface)(ppp_interface_id ID);
|
||||
@@ -53,12 +53,12 @@ typedef struct ppp_interface_module_info {
|
||||
size_t length);
|
||||
|
||||
int32 (*GetInterfaces)(ppp_interface_id *interfaces, int32 count,
|
||||
ppp_interface_filter filter = PPP_REGISTERED_INTERFACES);
|
||||
ppp_interface_filter filter);
|
||||
// make sure interfaces has enough space for count items
|
||||
int32 (*CountInterfaces)(ppp_interface_filter filter = PPP_REGISTERED_INTERFACES);
|
||||
int32 (*CountInterfaces)(ppp_interface_filter filter);
|
||||
|
||||
void (*EnableReports)(ppp_report_type type, thread_id thread,
|
||||
int32 flags = PPP_NO_FLAGS);
|
||||
int32 flags);
|
||||
void (*DisableReports)(ppp_report_type type, thread_id thread);
|
||||
bool (*DoesReport)(ppp_report_type type, thread_id thread);
|
||||
} ppp_interface_module_info;
|
||||
|
||||
@@ -16,6 +16,10 @@ class KPPPProtocol;
|
||||
|
||||
#include <Locker.h>
|
||||
|
||||
class PPPManager;
|
||||
class KPPPInterface;
|
||||
class KPPPLCP;
|
||||
|
||||
|
||||
class KPPPStateMachine {
|
||||
friend class PPPManager;
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
#ifdef _KERNEL_MODE
|
||||
#include <kernel_cpp.h>
|
||||
#else
|
||||
#include <new.h>
|
||||
#include <new>
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
@@ -106,7 +106,7 @@ private:
|
||||
|
||||
// sDefaultItem
|
||||
template<typename ITEM, typename DEFAULT_ITEM_SUPPLIER>
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t
|
||||
typename TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::sDefaultItem(
|
||||
DEFAULT_ITEM_SUPPLIER::GetItem());
|
||||
|
||||
@@ -134,7 +134,7 @@ TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::~TemplateList()
|
||||
// GetDefaultItem
|
||||
template<typename ITEM, typename DEFAULT_ITEM_SUPPLIER>
|
||||
inline
|
||||
const TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
const typename TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::GetDefaultItem() const
|
||||
{
|
||||
return sDefaultItem;
|
||||
@@ -143,7 +143,7 @@ TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::GetDefaultItem() const
|
||||
// GetDefaultItem
|
||||
template<typename ITEM, typename DEFAULT_ITEM_SUPPLIER>
|
||||
inline
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
typename TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::GetDefaultItem()
|
||||
{
|
||||
return sDefaultItem;
|
||||
@@ -315,7 +315,7 @@ TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::IsEmpty() const
|
||||
|
||||
// ItemAt
|
||||
template<typename ITEM, typename DEFAULT_ITEM_SUPPLIER>
|
||||
const TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
const typename TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::ItemAt(int32 index) const
|
||||
{
|
||||
if (index >= 0 && index < fItemCount)
|
||||
@@ -325,7 +325,7 @@ TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::ItemAt(int32 index) const
|
||||
|
||||
// ItemAt
|
||||
template<typename ITEM, typename DEFAULT_ITEM_SUPPLIER>
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
typename TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t &
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::ItemAt(int32 index)
|
||||
{
|
||||
if (index >= 0 && index < fItemCount)
|
||||
@@ -335,7 +335,7 @@ TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::ItemAt(int32 index)
|
||||
|
||||
// Items
|
||||
template<typename ITEM, typename DEFAULT_ITEM_SUPPLIER>
|
||||
const TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t *
|
||||
const typename TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::item_t *
|
||||
TemplateList<ITEM, DEFAULT_ITEM_SUPPLIER>::Items() const
|
||||
{
|
||||
return fItems;
|
||||
|
||||
@@ -19,7 +19,7 @@ static bool AddParameters(const BMessage& message, driver_settings *to);
|
||||
|
||||
bool
|
||||
FindMessageParameter(const char *name, const BMessage& message, BMessage *save,
|
||||
int32 *startIndex = NULL)
|
||||
int32 *startIndex)
|
||||
{
|
||||
// XXX: this should be removed when we can replace BMessage with something better
|
||||
BString string;
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
\param ID The ID of the new interface.
|
||||
*/
|
||||
PPPInterface::PPPInterface(ppp_interface_id ID = PPP_UNDEFINED_INTERFACE_ID)
|
||||
PPPInterface::PPPInterface(ppp_interface_id ID)
|
||||
{
|
||||
fFD = open(get_stack_driver_path(), O_RDWR);
|
||||
|
||||
@@ -290,7 +290,7 @@ PPPInterface::Down() const
|
||||
*/
|
||||
bool
|
||||
PPPInterface::EnableReports(ppp_report_type type, thread_id thread,
|
||||
int32 flags = PPP_NO_FLAGS) const
|
||||
int32 flags) const
|
||||
{
|
||||
ppp_report_request request;
|
||||
request.type = type;
|
||||
|
||||
@@ -245,7 +245,7 @@ PPPManager::DeleteInterface(ppp_interface_id ID) const
|
||||
*/
|
||||
ppp_interface_id*
|
||||
PPPManager::Interfaces(int32 *count,
|
||||
ppp_interface_filter filter = PPP_REGISTERED_INTERFACES) const
|
||||
ppp_interface_filter filter) const
|
||||
{
|
||||
int32 requestCount;
|
||||
ppp_interface_id *interfaces;
|
||||
@@ -278,7 +278,7 @@ PPPManager::Interfaces(int32 *count,
|
||||
//! Use \c Interfaces() instead of this method.
|
||||
int32
|
||||
PPPManager::GetInterfaces(ppp_interface_id *interfaces, int32 count,
|
||||
ppp_interface_filter filter = PPP_REGISTERED_INTERFACES) const
|
||||
ppp_interface_filter filter) const
|
||||
{
|
||||
ppp_get_interfaces_info info;
|
||||
info.interfaces = interfaces;
|
||||
@@ -376,8 +376,7 @@ PPPManager::InterfaceWithName(const char *name) const
|
||||
|
||||
//! Returns the number of existing interfaces or a negative value on error.
|
||||
int32
|
||||
PPPManager::CountInterfaces(ppp_interface_filter filter =
|
||||
PPP_REGISTERED_INTERFACES) const
|
||||
PPPManager::CountInterfaces(ppp_interface_filter filter) const
|
||||
{
|
||||
return Control(PPPC_COUNT_INTERFACES, &filter, sizeof(filter));
|
||||
}
|
||||
@@ -393,7 +392,7 @@ PPPManager::CountInterfaces(ppp_interface_filter filter =
|
||||
*/
|
||||
bool
|
||||
PPPManager::EnableReports(ppp_report_type type, thread_id thread,
|
||||
int32 flags = PPP_NO_FLAGS) const
|
||||
int32 flags) const
|
||||
{
|
||||
ppp_report_request request;
|
||||
request.type = type;
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
#include <string.h>
|
||||
|
||||
#include <MediaDefs.h>
|
||||
#include <Locker.h>
|
||||
#include <Path.h>
|
||||
|
||||
@@ -211,7 +211,7 @@ status_t MultiAudioAddOn::AutoStart(
|
||||
}
|
||||
|
||||
status_t
|
||||
MultiAudioAddOn::RecursiveScan(char* rootPath, BEntry *rootEntry = NULL)
|
||||
MultiAudioAddOn::RecursiveScan(char* rootPath, BEntry *rootEntry)
|
||||
{
|
||||
CALLED();
|
||||
|
||||
|
||||
@@ -954,7 +954,7 @@ MultiAudioNode::AdditionalBufferRequested(const media_source& source, media_buff
|
||||
void MultiAudioNode::HandleEvent(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
//CALLED();
|
||||
switch (event->type) {
|
||||
@@ -994,7 +994,7 @@ void MultiAudioNode::HandleEvent(
|
||||
status_t MultiAudioNode::HandleBuffer(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
//CALLED();
|
||||
BBuffer * buffer = const_cast<BBuffer*>((BBuffer*)event->pointer);
|
||||
@@ -1050,7 +1050,7 @@ status_t MultiAudioNode::HandleBuffer(
|
||||
status_t MultiAudioNode::HandleDataStatus(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
//CALLED();
|
||||
PRINT(("MultiAudioNode::HandleDataStatus status:%li, lateness:%li\n", event->data, lateness));
|
||||
@@ -1070,7 +1070,7 @@ status_t MultiAudioNode::HandleDataStatus(
|
||||
status_t MultiAudioNode::HandleStart(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
CALLED();
|
||||
if (RunState() != B_STARTED) {
|
||||
@@ -1082,7 +1082,7 @@ status_t MultiAudioNode::HandleStart(
|
||||
status_t MultiAudioNode::HandleSeek(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
CALLED();
|
||||
PRINT(("MultiAudioNode::HandleSeek(t=%lld,d=%li,bd=%lld)\n",event->event_time,event->data,event->bigdata));
|
||||
@@ -1092,7 +1092,7 @@ status_t MultiAudioNode::HandleSeek(
|
||||
status_t MultiAudioNode::HandleWarp(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
CALLED();
|
||||
return B_OK;
|
||||
@@ -1101,7 +1101,7 @@ status_t MultiAudioNode::HandleWarp(
|
||||
status_t MultiAudioNode::HandleStop(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
CALLED();
|
||||
// flush the queue so downstreamers don't get any more
|
||||
@@ -1114,7 +1114,7 @@ status_t MultiAudioNode::HandleStop(
|
||||
status_t MultiAudioNode::HandleParameter(
|
||||
const media_timed_event *event,
|
||||
bigtime_t lateness,
|
||||
bool realTimeEvent = false)
|
||||
bool realTimeEvent)
|
||||
{
|
||||
CALLED();
|
||||
return B_OK;
|
||||
|
||||
@@ -435,7 +435,7 @@ const mov_main_header *MOVFileReader::MovMainHeader()
|
||||
return &theMainHeader;
|
||||
}
|
||||
|
||||
const AudioMetaData *MOVFileReader::AudioFormat(uint32 stream_index, size_t *size = 0)
|
||||
const AudioMetaData *MOVFileReader::AudioFormat(uint32 stream_index, size_t *size)
|
||||
{
|
||||
if (IsAudio(stream_index)) {
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
* OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <malloc.h>
|
||||
#include <DataIO.h>
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include "MusePackDecoder.h"
|
||||
#include "mpc/in_mpc.h"
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include "idtag.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
//SettingsMPC PluginSettings; // AB: PluginSettings holds the parameters for the plugin-configuration
|
||||
|
||||
|
||||
@@ -52,6 +52,7 @@ private:
|
||||
// interface for OggStreams
|
||||
ssize_t ReadPage(bool first_page = false);
|
||||
|
||||
public:
|
||||
class StreamInterface {
|
||||
public:
|
||||
virtual ssize_t ReadPage() = 0;
|
||||
|
||||
@@ -201,7 +201,7 @@ VorbisDecoder::Decode(void *buffer, int64 *frameCount,
|
||||
packet.granulepos = -1;
|
||||
packet.packetno = 7;
|
||||
}
|
||||
packet.packet = static_cast<unsigned char *>(chunkBuffer);
|
||||
packet.packet = (unsigned char *)chunkBuffer;
|
||||
packet.bytes = chunkSize;
|
||||
if (!synced) {
|
||||
if (mh.start_time > 0) {
|
||||
|
||||
@@ -23,6 +23,8 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
using std::nothrow;
|
||||
|
||||
extern bool debug;
|
||||
|
||||
// "web safe palette"
|
||||
|
||||
@@ -56,16 +56,16 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// Translation Kit required globals
|
||||
char translatorName[] = "JPEG translator";
|
||||
char translatorInfo[] = "© 2002-2003, Shard
|
||||
|
||||
Based on IJG library © 1991-1998, Thomas G. Lane
|
||||
http://www.ijg.org/files/
|
||||
with \"Lossless\" encoding support patch by Ken Murchison
|
||||
http://www.oceana.com/ftp/ljpeg/
|
||||
|
||||
With some colorspace conversion routines by Magnus Hellman
|
||||
http://www.bebits.com/app/802
|
||||
";
|
||||
char translatorInfo[] = "© 2002-2003, Shard\n"
|
||||
"\n"
|
||||
"Based on IJG library © 1991-1998, Thomas G. Lane\"\n"
|
||||
" http://www.ijg.org/files/\n"
|
||||
"with \"Lossless\" encoding support patch by Ken Murchison\n"
|
||||
" http://www.oceana.com/ftp/ljpeg/\n"
|
||||
"\n"
|
||||
"With some colorspace conversion routines by Magnus Hellman\n"
|
||||
" http://www.bebits.com/app/802\n"
|
||||
"";
|
||||
int32 translatorVersion = 273; // 256 = v1.0.0
|
||||
|
||||
// Define the formats we know how to read
|
||||
|
||||
@@ -245,7 +245,7 @@ BaseTranslator::OutputFormats(int32 *out_count) const
|
||||
// ---------------------------------------------------------------
|
||||
status_t
|
||||
BaseTranslator::identify_bits_header(BPositionIO *inSource,
|
||||
translator_info *outInfo, TranslatorBitmap *pheader = NULL)
|
||||
translator_info *outInfo, TranslatorBitmap *pheader)
|
||||
{
|
||||
TranslatorBitmap header;
|
||||
|
||||
|
||||
@@ -107,8 +107,8 @@ AboutWindow::QuitRequested()
|
||||
}
|
||||
|
||||
|
||||
AboutView::AboutView(const BRect &r)
|
||||
: BView(r, "aboutview", B_FOLLOW_ALL, B_WILL_DRAW | B_PULSE_NEEDED),
|
||||
AboutView::AboutView(const BRect &rect)
|
||||
: BView(rect, "aboutview", B_FOLLOW_ALL, B_WILL_DRAW | B_PULSE_NEEDED),
|
||||
fLastActionTime(system_time()),
|
||||
fScrollRunner(NULL)
|
||||
{
|
||||
|
||||
@@ -168,9 +168,9 @@ EditorTabView::SetTypeEditorTab(BView *view)
|
||||
// #pragma mark -
|
||||
|
||||
|
||||
AttributeWindow::AttributeWindow(BRect rect, entry_ref *ref, const char *attribute,
|
||||
AttributeWindow::AttributeWindow(BRect _rect, entry_ref *ref, const char *attribute,
|
||||
const BMessage *settings)
|
||||
: ProbeWindow(rect, ref),
|
||||
: ProbeWindow(_rect, ref),
|
||||
fAttribute(strdup(attribute))
|
||||
{
|
||||
// Set alternative window title for devices
|
||||
|
||||
@@ -947,7 +947,7 @@ DataEditor::Update()
|
||||
|
||||
|
||||
status_t
|
||||
DataEditor::UpdateIfNeeded(bool *_updated = NULL)
|
||||
DataEditor::UpdateIfNeeded(bool *_updated)
|
||||
{
|
||||
if (!fNeedsUpdate) {
|
||||
if (_updated)
|
||||
|
||||
@@ -80,9 +80,9 @@ FileWindow::FileWindow(BRect rect, entry_ref *ref, const BMessage *settings)
|
||||
|
||||
// add our interface widgets
|
||||
|
||||
BRect rect = Bounds();
|
||||
rect.top = menuBar->Bounds().Height() + 1;
|
||||
fProbeView = new ProbeView(rect, ref, NULL, settings);
|
||||
BRect _rect = Bounds();
|
||||
_rect.top = menuBar->Bounds().Height() + 1;
|
||||
fProbeView = new ProbeView(_rect, ref, NULL, settings);
|
||||
AddChild(fProbeView);
|
||||
|
||||
fProbeView->AddSaveMenuItems(menu, 4);
|
||||
|
||||
@@ -351,9 +351,9 @@ FindTextView::GetData(BMessage &message)
|
||||
// #pragma mark -
|
||||
|
||||
|
||||
FindWindow::FindWindow(BRect rect, BMessage &previous, BMessenger &target,
|
||||
FindWindow::FindWindow(BRect _rect, BMessage &previous, BMessenger &target,
|
||||
const BMessage *settings)
|
||||
: BWindow(rect, "Find", B_TITLED_WINDOW, B_ASYNCHRONOUS_CONTROLS),
|
||||
: BWindow(_rect, "Find", B_TITLED_WINDOW, B_ASYNCHRONOUS_CONTROLS),
|
||||
fTarget(target)
|
||||
{
|
||||
BView *view = new BView(Bounds(), "main", B_FOLLOW_ALL, 0);
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
#include <FindDirectory.h>
|
||||
#include <Entry.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <Path.h>
|
||||
|
||||
// Format of Expander_Settings
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <interface/Box.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
RTColorControl::RTColorControl(BPoint point, BMessage *message)
|
||||
: BColorControl(point, B_CELLS_32x8, 6, "ColorControl", message, false) {
|
||||
|
||||
@@ -60,6 +60,8 @@
|
||||
#include "ShowImageView.h"
|
||||
#include "ShowImageWindow.h"
|
||||
|
||||
using std::nothrow;
|
||||
|
||||
#ifndef min
|
||||
#define min(a,b) ((a)>(b)?(b):(a))
|
||||
#endif
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
|
||||
// Implementation of RecentDocumentsMenu
|
||||
|
||||
RecentDocumentsMenu::RecentDocumentsMenu(const char *title, menu_layout layout = B_ITEMS_IN_COLUMN)
|
||||
RecentDocumentsMenu::RecentDocumentsMenu(const char *title, menu_layout layout)
|
||||
: BMenu(title, layout)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "TrackSlider.h"
|
||||
#include "icon_button.h"
|
||||
|
||||
@@ -15,6 +15,8 @@
|
||||
#include "TransportButton.h"
|
||||
#include "DrawingTidbits.h"
|
||||
|
||||
using std::map;
|
||||
|
||||
class BitmapStash {
|
||||
// Bitmap stash is a simple class to hold all the lazily-allocated
|
||||
// bitmaps that the TransportButton needs when rendering itself.
|
||||
|
||||
@@ -7,8 +7,8 @@
|
||||
#include "UpDownButton.h"
|
||||
#include "icon_button.h"
|
||||
|
||||
UpDownButton::UpDownButton(BRect rect, BMessage *msg, uint32 resizeFlags)
|
||||
: BControl(rect, "button", NULL, msg, resizeFlags, B_WILL_DRAW),
|
||||
UpDownButton::UpDownButton(BRect _rect, BMessage *msg, uint32 resizeFlags)
|
||||
: BControl(_rect, "button", NULL, msg, resizeFlags, B_WILL_DRAW),
|
||||
fLastValue(B_CONTROL_ON)
|
||||
{
|
||||
BRect rect = BRect(0, 0, kUpDownButtonWidth - 1, kUpDownButtonHeight - 1);
|
||||
|
||||
@@ -90,7 +90,7 @@ void StyledEditApp::DispatchMessage(BMessage *msg, BHandler *handler)
|
||||
if (msg->FindInt32("argc",&argc) != B_OK) {
|
||||
argc=0;
|
||||
}
|
||||
const char ** argv = new (const char*)[argc];
|
||||
const char ** argv = new const char*[argc];
|
||||
for (int arg = 0; (arg < argc) ; arg++) {
|
||||
if (msg->FindString("argv",arg,&argv[arg]) != B_OK) {
|
||||
argv[arg] = "";
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#include <Mime.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include <fs_info.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2004, Jérôme Duval, jerome.duval@free.fr.
|
||||
* Copyright 2004, J��e Duval, jerome.duval@free.fr.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include <String.h>
|
||||
#include <TextView.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
const uint32 TIMEDALERT_UPDATE = 'taup';
|
||||
|
||||
@@ -32,8 +33,8 @@ computer's clock may be an hour off. Currently,\nyour computer thinks it is "
|
||||
#define STRING2 ".\n\nIs this the correct time?"
|
||||
|
||||
TimedAlert::TimedAlert(const char *title, const char *text, const char *button1,
|
||||
const char *button2 = NULL, const char *button3 = NULL,
|
||||
button_width width = B_WIDTH_AS_USUAL, alert_type type = B_INFO_ALERT)
|
||||
const char *button2, const char *button3,
|
||||
button_width width, alert_type type)
|
||||
: BAlert(title, text, button1, button2, button3, width, type),
|
||||
fRunner(NULL)
|
||||
{
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
|
||||
#include <getopt.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
|
||||
|
||||
@@ -20,6 +20,9 @@
|
||||
#include <Path.h>
|
||||
#include <fs_volume.h>
|
||||
|
||||
using std::set;
|
||||
using std::string;
|
||||
|
||||
extern const char *__progname;
|
||||
|
||||
|
||||
|
||||
@@ -20,9 +20,10 @@
|
||||
|
||||
#include <PPPInterface.h>
|
||||
#include <settings_tools.h>
|
||||
#include <stl_algobase.h>
|
||||
#include <algorithm>
|
||||
// for max()
|
||||
|
||||
using std::max;
|
||||
|
||||
// GUI constants
|
||||
static const uint32 kDefaultButtonWidth = 80;
|
||||
|
||||
@@ -60,7 +60,7 @@ PPPDeskbarReplicant::Instantiate(BMessage *data)
|
||||
|
||||
|
||||
status_t
|
||||
PPPDeskbarReplicant::Archive(BMessage *data, bool deep = true) const
|
||||
PPPDeskbarReplicant::Archive(BMessage *data, bool deep) const
|
||||
{
|
||||
BView::Archive(data, deep);
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <String.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <getopt.h>
|
||||
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ for i in $(straceSyscallsIndices) {
|
||||
OPTIM = $(oldOptim) ;
|
||||
|
||||
BinCommand strace : $(straceSources)
|
||||
: $(straceSyscallsObjects) libroot.so libstdc++.r4.so ;
|
||||
: $(straceSyscallsObjects) libroot.so $(TARGET_LIBSTDC++) ;
|
||||
|
||||
# We need to specify the dependency on the generated syscalls file explicitly.
|
||||
Includes $(straceSyscallsSource) : <syscalls>strace_syscalls.h ;
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <debugger.h>
|
||||
|
||||
@@ -12,6 +12,9 @@
|
||||
|
||||
#include "TypeHandler.h"
|
||||
|
||||
using std::string;
|
||||
using std::vector;
|
||||
|
||||
// Type
|
||||
class Type {
|
||||
public:
|
||||
|
||||
@@ -25,23 +25,23 @@ public:
|
||||
template<typename value_t>
|
||||
static inline
|
||||
string
|
||||
get_number_value(const void *address, const char *format)
|
||||
get_number_value(value_t value, const char *format)
|
||||
{
|
||||
if (sizeof(align_t) > sizeof(value_t))
|
||||
return get_number_value<value_t>(value_t(*(align_t*)address), format);
|
||||
else
|
||||
return get_number_value<value_t>(*(value_t*)address, format);
|
||||
char buffer[32];
|
||||
sprintf(buffer, format, value);
|
||||
return buffer;
|
||||
}
|
||||
|
||||
// get_number_value
|
||||
template<typename value_t>
|
||||
static inline
|
||||
string
|
||||
get_number_value(value_t value, const char *format)
|
||||
get_number_value(const void *address, const char *format)
|
||||
{
|
||||
char buffer[32];
|
||||
sprintf(buffer, format, value);
|
||||
return buffer;
|
||||
if (sizeof(align_t) > sizeof(value_t))
|
||||
return get_number_value<value_t>(value_t(*(align_t*)address), format);
|
||||
else
|
||||
return get_number_value<value_t>(*(value_t*)address, format);
|
||||
}
|
||||
|
||||
// get_pointer_value
|
||||
|
||||
@@ -10,6 +10,8 @@
|
||||
#include <arch_config.h>
|
||||
#include <SupportDefs.h>
|
||||
|
||||
using std::string;
|
||||
|
||||
class MemoryReader;
|
||||
|
||||
typedef FUNCTION_CALL_PARAMETER_ALIGNMENT_TYPE align_t;
|
||||
|
||||
@@ -21,6 +21,10 @@
|
||||
#include "Syscall.h"
|
||||
#include "TypeHandler.h"
|
||||
|
||||
using std::map;
|
||||
using std::string;
|
||||
using std::vector;
|
||||
|
||||
extern void get_syscalls0(vector<Syscall*> &syscalls);
|
||||
extern void get_syscalls1(vector<Syscall*> &syscalls);
|
||||
extern void get_syscalls2(vector<Syscall*> &syscalls);
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
|
||||
#include "SymbolLookup.h"
|
||||
|
||||
using std::nothrow;
|
||||
using namespace BPrivate;
|
||||
|
||||
// PrepareAddress
|
||||
|
||||
@@ -13,6 +13,8 @@
|
||||
#include "arch_debug_support.h"
|
||||
#include "SymbolLookup.h"
|
||||
|
||||
using std::nothrow;
|
||||
|
||||
struct debug_symbol_lookup_context {
|
||||
debug_context context;
|
||||
SymbolLookup *lookup;
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
|
||||
// Standard Includes -----------------------------------------------------------
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
// System Includes -------------------------------------------------------------
|
||||
|
||||
@@ -37,6 +38,8 @@
|
||||
// Local Includes --------------------------------------------------------------
|
||||
#include <GameSound.h>
|
||||
|
||||
using std::nothrow;
|
||||
|
||||
// Local Defines ---------------------------------------------------------------
|
||||
|
||||
// BGameSound class ------------------------------------------------------------
|
||||
@@ -210,7 +213,7 @@ BGameSound::operator new(size_t size)
|
||||
|
||||
|
||||
void *
|
||||
BGameSound::operator new(size_t size, const nothrow_t &nt) throw()
|
||||
BGameSound::operator new(size_t size, const std::nothrow_t &nt) throw()
|
||||
{
|
||||
return ::operator new(size, nt);
|
||||
}
|
||||
@@ -226,7 +229,7 @@ BGameSound::operator delete(void *ptr)
|
||||
#if !__MWERKS__
|
||||
// there's a bug in MWCC under R4.1 and earlier
|
||||
void
|
||||
BGameSound::operator delete(void *ptr, const nothrow_t &nt) throw()
|
||||
BGameSound::operator delete(void *ptr, const std::nothrow_t &nt) throw()
|
||||
{
|
||||
::operator delete(ptr, nt);
|
||||
}
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
// Standard Includes -----------------------------------------------------------
|
||||
#include <string.h>
|
||||
|
||||
// System Includes -------------------------------------------------------------
|
||||
#include <List.h>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user