Skip to content

Commit

Permalink
Fix errors when building with DEBUG=2
Browse files Browse the repository at this point in the history
Fixes #8306. Please define DEBUG in UserBuildConfig or Jamfiles if
needed.
  • Loading branch information
pulkomandy committed Oct 31, 2014
1 parent 960598d commit f381456
Show file tree
Hide file tree
Showing 12 changed files with 7 additions and 17 deletions.
2 changes: 0 additions & 2 deletions src/add-ons/accelerants/matrox/be_driver_proto.h
Expand Up @@ -9,8 +9,6 @@
#include <Accelerant.h>
#include "video_overlay.h"

#define DEBUG 1

status_t INIT_ACCELERANT(int fd);
ssize_t ACCELERANT_CLONE_INFO_SIZE(void);
void GET_ACCELERANT_CLONE_INFO(void *data);
Expand Down
2 changes: 0 additions & 2 deletions src/add-ons/accelerants/neomagic/be_driver_proto.h
Expand Up @@ -9,8 +9,6 @@
#include <Accelerant.h>
#include "video_overlay.h"

#define DEBUG 1

status_t INIT_ACCELERANT(int fd);
ssize_t ACCELERANT_CLONE_INFO_SIZE(void);
void GET_ACCELERANT_CLONE_INFO(void *data);
Expand Down
2 changes: 0 additions & 2 deletions src/add-ons/accelerants/nvidia/be_driver_proto.h
Expand Up @@ -11,8 +11,6 @@
#include <Accelerant.h>
#include <video_overlay.h>

#define DEBUG 1

status_t INIT_ACCELERANT(int fd);
ssize_t ACCELERANT_CLONE_INFO_SIZE(void);
void GET_ACCELERANT_CLONE_INFO(void *data);
Expand Down
Expand Up @@ -259,7 +259,7 @@ AcpiUtDeleteInternalObj (
/* Global Lock has extra semaphore */

(void) AcpiOsDeleteSemaphore (AcpiGbl_GlobalLockSemaphore);
AcpiGbl_GlobalLockSemaphore = NULL;
AcpiGbl_GlobalLockSemaphore = 0;

AcpiOsDeleteMutex (Object->Mutex.OsMutex);
AcpiGbl_GlobalLockMutex = NULL;
Expand All @@ -278,7 +278,7 @@ AcpiUtDeleteInternalObj (
Object, Object->Event.OsSemaphore));

(void) AcpiOsDeleteSemaphore (Object->Event.OsSemaphore);
Object->Event.OsSemaphore = NULL;
Object->Event.OsSemaphore = 0;
break;

case ACPI_TYPE_METHOD:
Expand Down
Expand Up @@ -283,7 +283,7 @@ AcpiUtInitGlobals (

/* Global Lock support */

AcpiGbl_GlobalLockSemaphore = NULL;
AcpiGbl_GlobalLockSemaphore = 0;
AcpiGbl_GlobalLockMutex = NULL;
AcpiGbl_GlobalLockAcquired = FALSE;
AcpiGbl_GlobalLockHandle = 0;
Expand Down
2 changes: 0 additions & 2 deletions src/add-ons/kernel/drivers/disk/virtual/nbd/nbd.c
Expand Up @@ -53,8 +53,6 @@
#define mutex_unlock UNLOCK
#endif

#define DEBUG 1

#include "nbd.h"

#define DRV "nbd"
Expand Down
1 change: 0 additions & 1 deletion src/add-ons/print/drivers/pdf/source/Link.cpp
Expand Up @@ -27,7 +27,6 @@ THE SOFTWARE.
*/

#define DEBUG 1
#include <Debug.h>
#include <ctype.h>
#include "Link.h"
Expand Down
2 changes: 0 additions & 2 deletions src/apps/icon-o-matic/generic/selection/Selection.cpp
Expand Up @@ -14,8 +14,6 @@

#include "Selectable.h"

#define DEBUG 1

// constructor
Selection::Selection()
: fSelected(20)
Expand Down
1 change: 1 addition & 0 deletions src/apps/serialconnect/libvterm/src/encoding.c
Expand Up @@ -3,6 +3,7 @@
#define UNICODE_INVALID 0xFFFD

#if defined(DEBUG) && DEBUG > 1
# include <stdio.h>
# define DEBUG_PRINT_UTF8
#endif

Expand Down
4 changes: 3 additions & 1 deletion src/apps/serialconnect/libvterm/src/state.c
Expand Up @@ -228,6 +228,7 @@ static int on_text(const char bytes[], size_t len, void *user)
if(vterm_unicode_is_combining(codepoints[i])) {
/* See if the cursor has moved since */
if(state->pos.row == state->combine_pos.row && state->pos.col == state->combine_pos.col + state->combine_width) {
unsigned saved_i = 0;
#ifdef DEBUG_GLYPH_COMBINE
int printpos;
printf("DEBUG: COMBINING SPLIT GLYPH of chars {");
Expand All @@ -237,7 +238,6 @@ static int on_text(const char bytes[], size_t len, void *user)
#endif

/* Find where we need to append these combining chars */
unsigned saved_i = 0;
while(state->combine_chars[saved_i])
saved_i++;

Expand Down Expand Up @@ -287,11 +287,13 @@ static int on_text(const char bytes[], size_t len, void *user)
i--;

#ifdef DEBUG_GLYPH_COMBINE
{
int printpos;
printf("DEBUG: COMBINED GLYPH of %d chars {", glyph_ends - glyph_starts);
for(printpos = 0; printpos < glyph_ends - glyph_starts; printpos++)
printf("U+%04x ", chars[printpos]);
printf("}, onscreen width %d\n", width);
}
#endif

if(state->at_phantom || state->pos.col + width > THISROWWIDTH(state)) {
Expand Down
1 change: 0 additions & 1 deletion src/preferences/touchpad/TouchpadPref.h
Expand Up @@ -9,7 +9,6 @@
#define TOUCHPAD_PREF_H


#define DEBUG 1
#include <Debug.h>

#include "touchpad_settings.h"
Expand Down
1 change: 0 additions & 1 deletion src/preferences/touchpad/TouchpadPrefView.h
Expand Up @@ -21,7 +21,6 @@
#include "TouchpadPref.h"
#include "touchpad_settings.h"

#define DEBUG 1
#include <Debug.h>

#if DEBUG
Expand Down

0 comments on commit f381456

Please sign in to comment.