Changeset 3044


Ignore:
Timestamp:
Oct 19, 2008, 3:37:04 PM (11 years ago)
Author:
Pascal Terjan
Message:
  • APPLE should be handled like other cases where USE_GRAB is not defined (please test)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • neercs/trunk/src/mytrace.c

    r3000 r3044  
    3434#include "mytrace.h"
    3535
    36 #if defined(__APPLE__)
    37 
    38 struct mytrace* mytrace_attach(long int pid)
    39 {
    40     errno = ENOSYS;
    41     return NULL;
    42 }
    43 
    44 struct mytrace* mytrace_fork(struct mytrace *t)
    45 {
    46     errno = ENOSYS;
    47     return NULL;
    48 }
    49 
    50 int mytrace_detach(struct mytrace *t)
    51 {
    52     errno = ENOSYS;
    53     return -1;
    54 }
    55 
    56 long mytrace_getpid(struct mytrace *t)
    57 {
    58     errno = ENOSYS;
    59     return -1;
    60 }
    61 
    62 int mytrace_open(struct mytrace *t, char const *path, int mode)
    63 {
    64     errno = ENOSYS;
    65     return -1;
    66 }
    67 
    68 int mytrace_write(struct mytrace *t, int fd, char const *data, size_t len)
    69 {
    70     errno = ENOSYS;
    71     return -1;
    72 }
    73 
    74 int mytrace_close(struct mytrace *t, int fd)
    75 {
    76     errno = ENOSYS;
    77     return -1;
    78 }
    79 
    80 int mytrace_dup2(struct mytrace *t, int oldfd, int newfd)
    81 {
    82     errno = ENOSYS;
    83     return -1;
    84 }
    85 
    86 int mytrace_setpgid(struct mytrace *t, long pid, long pgid)
    87 {
    88     errno = ENOSYS;
    89     return -1;
    90 }
    91 
    92 int mytrace_setsid(struct mytrace *t)
    93 {
    94     errno = ENOSYS;
    95     return -1;
    96 }
    97 
    98 int mytrace_kill(struct mytrace *t, long pid, int sig)
    99 {
    100     errno = ENOSYS;
    101     return -1;
    102 }
    103 
    104 int mytrace_exit(struct mytrace *t, int status)
    105 {
    106     errno = ENOSYS;
    107     return -1;
    108 }
    109 
    110 int mytrace_exec(struct mytrace *t, char const *command)
    111 {
    112     errno = ENOSYS;
    113     return -1;
    114 }
    115 
    116 #else
    117 
    11836#if defined USE_GRAB
    11937static int memcpy_from_target(struct mytrace *t,
     
    12846#       define print_registers(x) do {} while(0)
    12947#   endif
    130 #endif
    13148
    13249#define X(x) #x
     
    186103    { "open", "close", "write", "dup2", "setpgid", "setsid", "kill", "fork",
    187104      "exit", "execve" };
     105
     106#endif /* USE_GRAB */
    188107
    189108struct mytrace
     
    760679
    761680#endif /* USE_GRAB */
    762 
    763 #endif /* ! defined(__APPLE__) */
Note: See TracChangeset for help on using the changeset viewer.