Enlightenment CVS committal Author : sebastid Project : e17 Module : apps/entrance
Dir : e17/apps/entrance/src/daemon Modified Files: Entranced.h auth.c ipc.c Log Message: Add missing headers. =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/entrance/src/daemon/Entranced.h,v retrieving revision 1.7 retrieving revision 1.8 diff -u -3 -r1.7 -r1.8 --- Entranced.h 20 May 2004 04:02:09 -0000 1.7 +++ Entranced.h 5 Sep 2005 12:05:57 -0000 1.8 @@ -13,6 +13,7 @@ #include <syslog.h> #include <Ecore.h> +#include <Ecore_Data.h> #include "../config.h" =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/entrance/src/daemon/auth.c,v retrieving revision 1.17 retrieving revision 1.18 diff -u -3 -r1.17 -r1.18 --- auth.c 9 Aug 2005 09:37:15 -0000 1.17 +++ auth.c 5 Sep 2005 12:05:57 -0000 1.18 @@ -85,14 +85,14 @@ while ((auth = XauReadAuth(auth_file))) { int match; - match = FALSE; + match = 0; for (li = d->auths->first; li; li = li->next) { Xauth *disp_auth = (Xauth *) li->data; if (!memcmp(disp_auth->address, auth->address, auth->address_length) && !memcmp(disp_auth->number, auth->number, auth->number_length)) - match = TRUE; + match = 1; } if (match) @@ -267,18 +267,18 @@ char dispnum[8]; if (!d) - return FALSE; + return 0; /* Generate a new Xauth and set the address */ if (!(auth = _entranced_auth_generate())) - return FALSE; + return 0; auth->family = FamilyLocal; auth->address = calloc(1, addrlen); if(!auth->address) { free(auth); - return FALSE; + return 0; } memcpy(auth->address, addr, addrlen); auth->address_length = addrlen; @@ -288,7 +288,7 @@ if (!auth->address) { free(auth); - return FALSE; + return 0; } #endif @@ -300,7 +300,7 @@ if (!XauWriteAuth(auth_file, auth)) { entranced_debug("_entrance_auth_entry_add: Auth write failed!\n"); - return FALSE; + return 0; } if (!d->auths) @@ -312,10 +312,10 @@ if (!ecore_list_append(d->auths, auth)) { entranced_debug("_entrance_auth_entry_add: Could not add auth entry to list!\n"); - return FALSE; + return 0; } - return TRUE; + return 1; } @@ -330,7 +330,7 @@ char hostname[1024]; if (!d) - return FALSE; + return 0; umask(022); @@ -348,7 +348,7 @@ { free(d->authfile); d->authfile = NULL; - return FALSE; + return 0; } /* XXX: This code assumes X server is running on localhost and @@ -373,10 +373,10 @@ /* Add auth entry for local host */ if (!_entranced_auth_entry_add(d, auth_file, d->hostname, strlen(d->hostname))) - return FALSE; + return 0; fclose(auth_file); - setenv("XAUTHORITY", d->authfile, TRUE); + setenv("XAUTHORITY", d->authfile, 1); /* TODO: This will become a config option -- perhaps desirable for * single-user systems, but not multi-user machines. @@ -388,7 +388,7 @@ if (!(host_file = fopen(buf, "w"))) { entranced_debug("entranced_auth_display_secure: Unable to open %s for writing\n", buf); - return FALSE; + return 0; } fprintf(host_file, "%s\n", d->hostname); fclose(host_file); @@ -396,19 +396,19 @@ entranced_debug("entranced_auth_display_secure: Successfully set up access for %s (localhost)\n", d->name); - return TRUE; + return 1; } int entranced_auth_user_add(Entranced_Display *d, const char *homedir) { FILE *auth_file; - int ret = TRUE; + int ret = 1; char buf[PATH_MAX]; Ecore_List_Node *li; if (!d || !homedir) - return FALSE; + return 0; entranced_debug("entranced_auth_user_add: Adding auth cookie\n"); @@ -434,7 +434,7 @@ free(d->client.authfile); d->client.authfile = NULL; seteuid(0); - return FALSE; + return 0; } /* TODO: May need a permissions/paranoia check */ @@ -467,7 +467,7 @@ seteuid(0); umask (022); - return FALSE; + return 0; } entranced_debug("entranced_auth_user_add: Opened %s for writing cookies\n", d->client.authfile); @@ -480,7 +480,7 @@ if (!XauWriteAuth (auth_file, (Xauth *) li->data)) { syslog(LOG_CRIT, "entranced_user_auth_add: Unable to write cookie"); - ret = FALSE; + ret = 0; break; } } =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/entrance/src/daemon/ipc.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -3 -r1.6 -r1.7 --- ipc.c 28 May 2005 11:45:03 -0000 1.6 +++ ipc.c 5 Sep 2005 12:05:57 -0000 1.7 @@ -16,10 +16,10 @@ Ecore_Ipc_Event_Client_Add *e; if (!(e = (Ecore_Ipc_Event_Client_Add *) event)) - return TRUE; + return 1; entranced_debug("_entranced_ipc_client_add: Received event\n"); - return TRUE; + return 1; } static int @@ -28,10 +28,10 @@ Ecore_Ipc_Event_Client_Del *e; if (!(e = (Ecore_Ipc_Event_Client_Del *) event)) - return TRUE; + return 1; entranced_debug("_entranced_ipc_client_del: Received event\n"); - return TRUE; + return 1; } static int @@ -40,7 +40,7 @@ Ecore_Ipc_Event_Client_Data *e; if (!(e = (Ecore_Ipc_Event_Client_Data *) event) || !_display) - return TRUE; + return 1; /* FIXME: This assumes there is only one client ... client will * need to pass its pid or other verification data in the @@ -83,7 +83,7 @@ entranced_debug("_entranced_ipc_client_data: Received [%i] [%i] [%i] [%i] \"%s\"\n", e->major, e->minor, e->size, e->response, (char *) e->data); - return TRUE; + return 1; } int @@ -92,7 +92,7 @@ char buf[PATH_MAX]; if (!(ecore_ipc_init())) - return FALSE; + return 0; /* Make sure this path exists */ ecore_file_mkpath(PACKAGE_STATE_DIR); @@ -113,7 +113,7 @@ if (!(server = ecore_ipc_server_add(ECORE_IPC_LOCAL_SYSTEM, ipc_title, 0, NULL))) { entranced_debug("entranced_ipc_init: Failed to open socket %s.\n", ipc_title); - return FALSE; + return 0; } if (clients) @@ -122,7 +122,7 @@ entranced_debug("entranced_ipc_init: Success\n"); - return TRUE; + return 1; } void ------------------------------------------------------- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs