--- rxvt-unicode/src/misc.C 2006/01/20 10:27:08 1.36 +++ rxvt-unicode/src/misc.C 2006/02/20 22:40:35 1.39 @@ -6,7 +6,7 @@ * Copyright (c) 1996 mj olesen Queen's Univ at Kingston * Copyright (c) 1997,1998 Oezguer Kesim * Copyright (c) 1998-2000 Geoff Wing - * Copyright (c) 2003-2004 Marc Lehmann + * Copyright (c) 2003-2006 Marc Lehmann * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -431,8 +431,6 @@ * file searching */ -/* #define DEBUG_SEARCH_PATH */ - #ifdef XPM_BACKGROUND /* * search for FILE in the current working directory, and within the @@ -440,7 +438,7 @@ * * FILE is either semi-colon or zero terminated */ -char * +char * rxvt_File_search_path (const char *pathlist, const char *file, const char *ext) NOTHROW { int maxpath, len; @@ -456,12 +454,6 @@ else len = strlen (file); -#ifdef DEBUG_SEARCH_PATH - getcwd (name, sizeof (name)); - fprintf (stderr, "pwd: \"%s\"\n", name); - fprintf (stderr, "find: \"%.*s\"\n", len, file); -#endif - /* leave room for an extra '/' and trailing '\0' */ maxpath = sizeof (name) - (len + (ext ? strlen (ext) : 0) + 2); if (maxpath <= 0) @@ -512,7 +504,7 @@ return NULL; } -char * +char * rxvt_File_find (const char *file, const char *ext, const char *path) NOTHROW { char *f; @@ -522,33 +514,8 @@ f = rxvt_File_search_path (path, file, ext); -#ifdef DEBUG_SEARCH_PATH - if (f) - fprintf (stderr, "found: \"%s\"\n", f); -#endif - return f; } #endif -// should not be used in interactive programs, for obvious reasons -void rxvt_usleep (int usecs) NOTHROW -{ -#if HAVE_NANOSLEEP - struct timespec ts; - - ts.tv_sec = 0; - ts.tv_nsec = usecs * 1000; - nanosleep (&ts, NULL); -#else - /* use select for timing */ - struct timeval tv; - - tv.tv_sec = 0; - tv.tv_usec = usecs; - select (0, NULL, NULL, NULL, &tv); -#endif -} - -/*----------------------- end-of-file (C source) -----------------------*/