VirtualBox

Ignore:
Timestamp:
Aug 9, 2016 2:25:27 PM (8 years ago)
Author:
vboxsync
Message:

dtrace: warnings (gcc)

Location:
trunk/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_module.c

    r62829 r63207  
    830830}
    831831
     832#ifndef VBOX
    832833/*
    833834 * Update our module cache by adding an entry for the specified module 'name'.
     
    837838dt_module_update(dtrace_hdl_t *dtp, const char *name)
    838839{
    839 #ifndef VBOX
    840840        char fname[MAXPATHLEN];
    841841        struct stat64 st;
     
    929929        dt_dprintf("opened %d-bit module %s (%s) [%d]\n",
    930930            bits, dmp->dm_name, dmp->dm_file, dmp->dm_modid);
    931 #else  /* VBOX */
    932         RT_NOREF2(dtp, name);
    933 #endif /* VBOX */
    934 }
     931}
     932#endif /* !VBOX */
    935933
    936934/*
     
    10131011        dt_module_t *dmp;
    10141012
    1015         switch ((uintptr_t)object) {
    1016         case (uintptr_t)DTRACE_OBJ_EXEC:
     1013        switch ((intptr_t)object) {
     1014        case DTRACE_OBJ_INT_EXEC:
    10171015                dmp = dtp->dt_exec;
    10181016                break;
    1019         case (uintptr_t)DTRACE_OBJ_RTLD:
     1017        case DTRACE_OBJ_INT_RTLD:
    10201018                dmp = dtp->dt_rtld;
    10211019                break;
    1022         case (uintptr_t)DTRACE_OBJ_CDEFS:
     1020        case DTRACE_OBJ_INT_CDEFS:
    10231021                dmp = dtp->dt_cdefs;
    10241022                break;
    1025         case (uintptr_t)DTRACE_OBJ_DDEFS:
     1023        case DTRACE_OBJ_INT_DDEFS:
    10261024                dmp = dtp->dt_ddefs;
    10271025                break;
  • trunk/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_open.c

    r62829 r63207  
    796796}
    797797
     798#ifndef VBOX
    798799static const char *
    799800dt_get_sysinfo(int cmd, char *buf, size_t len)
    800801{
    801 #ifndef VBOX
    802802        ssize_t rv = sysinfo(cmd, buf, len);
    803803        char *p = buf;
     
    808808        while ((p = strchr(p, '.')) != NULL)
    809809                *p++ = '_';
    810 #else
    811         RT_NOREF1(cmd);
    812         snprintf(buf, len, "%s", "Unknown");
    813 #endif
    814810        return (buf);
    815811}
     812#endif /* !VBOX */
    816813
    817814static dtrace_hdl_t *
  • trunk/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_options.c

    r62829 r63207  
    744744                }
    745745
    746                 if (suffix[i].name == NULL && *end != '\0' || val < 0)
     746                if ((suffix[i].name == NULL && *end != '\0') || val < 0)
    747747                        return (dt_set_errno(dtp, EDT_BADOPTVAL));
    748748
  • trunk/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_work.c

    r62829 r63207  
    3636#else  /* VBOX */
    3737# include <dt_impl.h>
    38 //# include <stddef.h>
    39 //# include <time.h>
     38/*# include <stddef.h>
     39# include <time.h> */
    4040# include <iprt/semaphore.h>
    4141#endif /* VBOX */
  • trunk/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dtrace.h

    r62829 r63207  
    443443 */
    444444
    445 #define DTRACE_OBJ_EXEC  ((const char *)(intptr_t)0L)   /* primary executable file */
    446 #define DTRACE_OBJ_RTLD  ((const char *)(intptr_t)1L)   /* run-time link-editor */
    447 #define DTRACE_OBJ_CDEFS ((const char *)(intptr_t)2L)   /* C include definitions */
    448 #define DTRACE_OBJ_DDEFS ((const char *)(intptr_t)3L)   /* D program definitions */
    449 #define DTRACE_OBJ_EVERY ((const char *)(intptr_t)-1L)  /* all known objects */
    450 #define DTRACE_OBJ_KMODS ((const char *)(intptr_t)-2L)  /* all kernel objects */
    451 #define DTRACE_OBJ_UMODS ((const char *)(intptr_t)-3L)  /* all user objects */
     445#define DTRACE_OBJ_INT_EXEC  (0L)       /* primary executable file */
     446#define DTRACE_OBJ_INT_RTLD  (1L)       /* run-time link-editor */
     447#define DTRACE_OBJ_INT_CDEFS (2L)       /* C include definitions */
     448#define DTRACE_OBJ_INT_DDEFS (3L)       /* D program definitions */
     449#define DTRACE_OBJ_INT_EVERY (-1L)      /* all known objects */
     450#define DTRACE_OBJ_INT_KMODS (-2L)      /* all kernel objects */
     451#define DTRACE_OBJ_INT_UMODS (-3L)      /* all user objects */
     452
     453#define DTRACE_OBJ_EXEC  ((const char *)(intptr_t)DTRACE_OBJ_INT_EXEC ) /* primary executable file */
     454#define DTRACE_OBJ_RTLD  ((const char *)(intptr_t)DTRACE_OBJ_INT_RTLD ) /* run-time link-editor */
     455#define DTRACE_OBJ_CDEFS ((const char *)(intptr_t)DTRACE_OBJ_INT_CDEFS) /* C include definitions */
     456#define DTRACE_OBJ_DDEFS ((const char *)(intptr_t)DTRACE_OBJ_INT_DDEFS) /* D program definitions */
     457#define DTRACE_OBJ_EVERY ((const char *)(intptr_t)DTRACE_OBJ_INT_EVERY) /* all known objects */
     458#define DTRACE_OBJ_KMODS ((const char *)(intptr_t)DTRACE_OBJ_INT_KMODS) /* all kernel objects */
     459#define DTRACE_OBJ_UMODS ((const char *)(intptr_t)DTRACE_OBJ_INT_UMODS) /* all user objects */
    452460
    453461typedef struct dtrace_objinfo {
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette