New Ticket     Tickets     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Changeset 80129


Ignore:
Timestamp:
07/04/11 20:53:54 (4 years ago)
Author:
jmr@…
Message:

merge r80069 from trunk:

Rename dprintf to debug_printf to avoid name clash with POSIX

Location:
branches/release_2_0
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • branches/release_2_0

  • branches/release_2_0/base

  • branches/release_2_0/base/portmgr/fedora/macports.spec

  • branches/release_2_0/base/src/darwintracelib1.0/darwintrace.c

    r79597 r80129  
    164164#if __STDC_VERSION__>=199901L 
    165165#if DARWINTRACE_DEBUG_OUTPUT 
    166 #define dprintf(...) fprintf(stderr, __VA_ARGS__) 
     166#define debug_printf(...) fprintf(stderr, __VA_ARGS__) 
    167167#else 
    168 #define dprintf(...) 
     168#define debug_printf(...) 
    169169#endif 
    170170#else 
     
    172172__attribute__ ((format (printf, 1, 2))) 
    173173static inline 
    174 int dprintf(const char *format, ...) { 
     174int debug_printf(const char *format, ...) { 
    175175    int ret; 
    176176    va_list args; 
     
    181181} 
    182182#else 
    183 #define dprintf(format, param) 
     183#define debug_printf(format, param) 
    184184#endif 
    185185#endif 
     
    363363                        if(connect(sock, (struct sockaddr*)&sun, strlen(__env_darwintrace_log)+1+sizeof(sun.sun_family))!=-1) 
    364364                        { 
    365                                 dprintf("darwintrace: connect successful. socket %d\n", sock); 
     365                                debug_printf("darwintrace: connect successful. socket %d\n", sock); 
    366366                                __darwintrace_fd=sock; 
    367367                                ask_for_filemap(); 
    368368                        } else { 
    369                                 dprintf("connect failed: %s\n", strerror(errno)); 
     369                                debug_printf("connect failed: %s\n", strerror(errno)); 
    370370                                abort(); 
    371371                        } 
     
    470470  } 
    471471 
    472   dprintf("darwintrace: cleanup resulted in %s\n", path); 
     472  debug_printf("darwintrace: cleanup resulted in %s\n", path); 
    473473} 
    474474 
     
    664664                isInSandbox = __darwintrace_is_in_sandbox(path, newpath); 
    665665                if (isInSandbox == 0) { 
    666                         dprintf("darwintrace: creation/writing was forbidden at %s\n", path); 
     666                        debug_printf("darwintrace: creation/writing was forbidden at %s\n", path); 
    667667                        errno = EACCES; 
    668668                        result = -1; 
     
    810810        int isInSandbox = __darwintrace_is_in_sandbox(path, 0); 
    811811        if (isInSandbox == 1) { 
    812                 dprintf("darwintrace: unlink was allowed at %s\n", path); 
     812                debug_printf("darwintrace: unlink was allowed at %s\n", path); 
    813813        } else if (isInSandbox == 0) { 
    814814                /* outside sandbox, but sandbox is defined: forbid */ 
    815                 dprintf("darwintrace: unlink was forbidden at %s\n", path); 
     815                debug_printf("darwintrace: unlink was forbidden at %s\n", path); 
    816816                errno = EACCES; 
    817817                result = -1; 
     
    832832        int isInSandbox = __darwintrace_is_in_sandbox(path, 0); 
    833833        if (isInSandbox == 1) { 
    834                 dprintf("darwintrace: mkdir was allowed at %s\n", path); 
     834                debug_printf("darwintrace: mkdir was allowed at %s\n", path); 
    835835        } else if (isInSandbox == 0) { 
    836836                /* outside sandbox, but sandbox is defined: forbid */ 
     
    841841                if ((err == -1) && (errno == ENOENT)) 
    842842                { 
    843                         dprintf("darwintrace: mkdir was forbidden at %s\n", path); 
     843                        debug_printf("darwintrace: mkdir was forbidden at %s\n", path); 
    844844                        errno = EACCES; 
    845845                        result = -1; 
     
    862862        int isInSandbox = __darwintrace_is_in_sandbox(path, 0); 
    863863        if (isInSandbox == 1) { 
    864                 dprintf("darwintrace: rmdir was allowed at %s\n", path); 
     864                debug_printf("darwintrace: rmdir was allowed at %s\n", path); 
    865865        } else if (isInSandbox == 0) { 
    866866                /* outside sandbox, but sandbox is defined: forbid */ 
    867                 dprintf("darwintrace: removing directory %s was forbidden\n", path); 
     867                debug_printf("darwintrace: removing directory %s was forbidden\n", path); 
    868868                errno = EACCES; 
    869869                result = -1; 
     
    884884        int isInSandbox = __darwintrace_is_in_sandbox(from, 0); 
    885885        if (isInSandbox == 1) { 
    886                 dprintf("darwintrace: rename was allowed at %s\n", from); 
     886                debug_printf("darwintrace: rename was allowed at %s\n", from); 
    887887        } else if (isInSandbox == 0) { 
    888888                /* outside sandbox, but sandbox is defined: forbid */ 
    889                 dprintf("darwintrace: renaming from %s was forbidden\n", from); 
     889                debug_printf("darwintrace: renaming from %s was forbidden\n", from); 
    890890                errno = EACCES; 
    891891                result = -1; 
     
    895895                isInSandbox = __darwintrace_is_in_sandbox(to, 0); 
    896896                if (isInSandbox == 1) { 
    897                         dprintf("darwintrace: rename was allowed at %s\n", to); 
     897                        debug_printf("darwintrace: rename was allowed at %s\n", to); 
    898898                } else if (isInSandbox == 0) { 
    899899                        /* outside sandbox, but sandbox is defined: forbid */ 
    900                         dprintf("darwintrace: renaming to %s was forbidden\n", to); 
     900                        debug_printf("darwintrace: renaming to %s was forbidden\n", to); 
    901901                        errno = EACCES; 
    902902                        result = -1; 
  • branches/release_2_0/base/src/pextlib1.0/sha2.c

    • Property svn:mergeinfo changed (with no actual effect on merging)
  • branches/release_2_0/base/src/pextlib1.0/sha2.h

    • Property svn:mergeinfo changed (with no actual effect on merging)
  • branches/release_2_0/base/src/pextlib1.0/sha256cmd.c

    • Property svn:mergeinfo changed (with no actual effect on merging)
  • branches/release_2_0/base/src/pextlib1.0/sha256cmd.h

    • Property svn:mergeinfo changed (with no actual effect on merging)
  • branches/release_2_0/base/src/registry2.0/receipt_sqlite.tcl

    • Property svn:mergeinfo changed (with no actual effect on merging)
Note: See TracChangeset for help on using the changeset viewer.