From 261f99bdac9a995f8b2740b7ae52c8ad81001132 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Thu, 2 Aug 2007 15:00:07 +0000 Subject: 2007-08-02 Joel Sherrill * configure.ac, wrapup/Makefile.am: Remove RDBG. * aclocal/check-rdbg.m4, aclocal/enable-rdbg.m4, librdbg/.cvsignore, librdbg/Makefile.am, librdbg/preinstall.am, librdbg/include/rdbg/rdbg.h, librdbg/include/rdbg/servrpc.h, librdbg/include/rdbg/i386/rdbg_f.h, librdbg/include/rdbg/i386/reg.h, librdbg/include/rdbg/m68k/rdbg_f.h, librdbg/include/rdbg/m68k/reg.h, librdbg/include/rdbg/powerpc/rdbg_f.h, librdbg/include/rdbg/powerpc/reg.h, librdbg/src/_servtgt.c, librdbg/src/awk.svc, librdbg/src/excep.c, librdbg/src/ptrace.c, librdbg/src/rdbg.c, librdbg/src/remdeb.x, librdbg/src/servbkpt.c, librdbg/src/servcon.c, librdbg/src/servrpc.c, librdbg/src/servtgt.c, librdbg/src/servtsp.c, librdbg/src/servutil.c, librdbg/src/i386/excep_f.c, librdbg/src/i386/rdbg_cpu_asm.S, librdbg/src/i386/rdbg_f.c, librdbg/src/i386/any/remdeb.h, librdbg/src/i386/any/remdeb_f.x, librdbg/src/i386/any/remdeb_svc.c, librdbg/src/i386/any/remdeb_xdr.c, librdbg/src/m68k/excep_f.c, librdbg/src/m68k/rdbg_cpu_asm.S, librdbg/src/m68k/rdbg_f.c, librdbg/src/m68k/any/remdeb.h, librdbg/src/m68k/any/remdeb_f.x, librdbg/src/m68k/any/remdeb_svc.c, librdbg/src/m68k/any/remdeb_xdr.c, librdbg/src/powerpc/excep_f.c, librdbg/src/powerpc/rdbg_cpu_asm.S, librdbg/src/powerpc/rdbg_f.c, librdbg/src/powerpc/new_exception_processing/remdeb.h, librdbg/src/powerpc/new_exception_processing/remdeb_f.x, librdbg/src/powerpc/new_exception_processing/remdeb_svc.c, librdbg/src/powerpc/new_exception_processing/remdeb_xdr.c: Removed. --- c/src/librdbg/src/servutil.c | 135 ------------------------------------------- 1 file changed, 135 deletions(-) delete mode 100644 c/src/librdbg/src/servutil.c (limited to 'c/src/librdbg/src/servutil.c') diff --git a/c/src/librdbg/src/servutil.c b/c/src/librdbg/src/servutil.c deleted file mode 100644 index e7cf184703..0000000000 --- a/c/src/librdbg/src/servutil.c +++ /dev/null @@ -1,135 +0,0 @@ -/* - ********************************************************************** - * - * Component: RDB - * Module: servutil.c - * - * Synopsis: Various utility routines - * - * $Id$ - * - ********************************************************************** - */ - -#include -#include -#include - -/*----- Management of per-process list ----*/ - - /* - * ListAlloc - build up list entry. - * - * Notes: - * - this is a generic routine to build up entries in the per-connection - * list. The fields list, list_sz and list_alloc are affected. - */ - - Boolean -ListAlloc (buff, clst) - char *buff; - CONN_LIST *clst; /* place to copy it */ -{ - int tmp; - char *name; - int new_len; - int len; - - tmp = strlen (buff); - new_len = (int) clst->list_sz + 1 + tmp; - if (clst->list_alloc < (unsigned) new_len) { - /* - * need more space - */ - name = (char *) Realloc (clst->list, len = new_len + MAX_FILENAME); - if (name == NULL) { - return (False); /* failed, no space */ - } - clst->list_alloc = len; - clst->list = name; - } - strcpy (clst->list + clst->list_sz, buff); - clst->list_sz += tmp; - return (True); -} - -/*----- Management of processes -----*/ - - /* - * FindPidEntry - locate pid_list entry from pid - */ - - int -FindPidEntry (int pid) /* pid = process identifier */ -{ - int idx; - - /* - * pid 0 is invalid, and signals a free slot - */ - if (pid_list == NULL || pid == 0) { - return -1; - } - for (idx = 0; idx < pid_list_cnt; idx++) { - if (pid_list[idx].pid == pid) - return idx; - } - return -1; -} - -/*----- Debug suport -----*/ - -#ifdef DDEBUG - - /* - * Names of debug primitives - */ - -const char *PtraceNames[] = { - - "RPT_TRACEME", "RPT_PEEKTEXT", "RPT_PEEKDATA", "RPT_PEEKUSER", - "RPT_POKETEXT", "RPT_POKEDATA", "RPT_POKEUSER", "RPT_CONT", - "RPT_KILL", "RPT_SINGLESTEP", "RPT_ATTACH", "RPT_DETACH", - "RPT_GETREGS", "RPT_SETREGS", "RPT_GETFPREGS", "RPT_SETFPREGS", - "RPT_READDATA", "RPT_WRITEDATA", "RPT_READTEXT", "RPT_WRITETEXT", - "RPT_GETFPAREGS", "RPT_SETFPAREGS", "RPT_22", "RPT_23", - "RPT_SYSCALL", "RPT_DUMPCORE", "RPT_26", "RPT_27", - "RPT_28", "RPT_GETUCODE", "RPT_30", "RPT_31", - "RPT_32", "RPT_33", "RPT_34", "RPT_35", - "RPT_36", "RPT_37", "RPT_38", "RPT_39", - "RPT_40", "RPT_41", "RPT_42", "RPT_43", - "RPT_44", "RPT_45", "RPT_46", "RPT_47", - "RPT_48", "RPT_49", "RPT_GETTARGETTHREAD", "RPT_SETTARGETTHREAD", - "RPT_THREADSUSPEND", "RPT_THREADRESUME", "RPT_THREADLIST", - "RPT_GETTHREADNAME", - "RPT_SETTHREADNAME", "RPT_SETTHREADREGS", "RPT_GETTHREADREGS", - "RPT_59", - "RPT_60", "RPT_61", "RPT_62", "RPT_63", - "RPT_64", "RPT_65", "RPT_66", "RPT_67", - "RPT_68", "RPT_69", "RPT_70", "RPT_71", - "RPT_72", "RPT_73", "RPT_74", "RPT_STEPRANGE", - "RPT_CONTTO", "RPT_SETBREAK", "RPT_CLRBREAK", "RPT_GETBREAK", - "RPT_GETNAME", "RPT_STOP", - "RPT_PGETREGS", "RPT_PSETREGS", - "RPT_PSETTHREADREGS", "RPT_PGETTHREADREGS" -}; - - const char * -PtraceName (int req) -{ - static char bufret[40]; - - if ((req < 0) || (req >= sizeof (PtraceNames) / sizeof (char *))) { - sprintf (bufret, "BAD_REQ_%d", req); - return bufret; - } - return PtraceNames[req]; -} - -const char *BmsgNames[] = { - "?", "WARM", "WAIT", "BREAK", - "EXEC_FAIL", "DETACH", "KILLED", "NOT_PRIM", - "NEW_PID" -}; - -#endif /* DDEBUG */ -- cgit v1.2.3