diff cinst/nssstore_win.c @ 905:698b6a9bd75e

Fix coding style for C code astyle --style=gnu --indent=spaces=2
author Andre Heinecke <andre.heinecke@intevation.de>
date Wed, 13 Aug 2014 15:49:47 +0200
parents 797aa8d9c785
children 427e2e18b8c8
line wrap: on
line diff
--- a/cinst/nssstore_win.c	Wed Aug 13 15:44:35 2014 +0200
+++ b/cinst/nssstore_win.c	Wed Aug 13 15:49:47 2014 +0200
@@ -71,7 +71,8 @@
 #define PROFILE_LIST L"Software\\Microsoft\\Windows NT\\CurrentVersion\\ProfileList"
 #define RUNONCE_PATH L"Software\\Microsoft\\Windows\\CurrentVersion\\RunOnce"
 
-struct profile_key_path {
+struct profile_key_path
+{
   char *sid;
   char *hive_path;
   struct profile_key_path *next;
@@ -118,13 +119,13 @@
       return NULL;
     }
 
-   if (!SaferComputeTokenFromLevel(user_level, NULL, &retval, 0, NULL))
+  if (!SaferComputeTokenFromLevel(user_level, NULL, &retval, 0, NULL))
     {
-        SaferCloseLevel(user_level);
-        return NULL;
+      SaferCloseLevel(user_level);
+      return NULL;
     }
 
-   return retval;
+  return retval;
 }
 
 /**@brief Write strv of instructions to a handle
@@ -227,7 +228,7 @@
   wchar_t key_name[257],
           *current_user_sid = NULL;
   pkp_t *retval = NULL,
-        *cur_item = NULL;
+         *cur_item = NULL;
   bool error = true;
   PSID current_user = NULL;
 
@@ -376,7 +377,7 @@
   /* installdir + dirsep +  quotes + process name + space + quotes + selection_file
      + NULL */
   cmd_line_len = wcslen (w_inst_dir) + 1 + 2 + wcslen (NSS_APP_NAME) +
-    + 1 + 2 + wcslen(selection_file) + 1;
+                 + 1 + 2 + wcslen(selection_file) + 1;
   retval = xmalloc (cmd_line_len * sizeof(wchar_t));
 
   wcscpy_s (retval, cmd_line_len, L"\"");
@@ -508,7 +509,7 @@
 register_proccesses_for_others (wchar_t *selection_file)
 {
   pkp_t *pkplist = locate_other_hives(),
-        *cur = NULL;
+         *cur = NULL;
   wchar_t *run_command = NULL;
 
   if (pkplist == NULL)
@@ -547,7 +548,7 @@
              in the standard location or already loaded. Try to access
              the loaded registry in that case*/
           wchar_t *user_key = NULL,
-                  *w_sid = NULL;
+                   *w_sid = NULL;
           size_t user_key_len = 0;
 
           SetLastError((DWORD)ret);
@@ -817,7 +818,7 @@
 
   /* Initialize a security descriptor */
   descriptor = (PSECURITY_DESCRIPTOR) LocalAlloc(LPTR,
-                                                 SECURITY_DESCRIPTOR_MIN_LENGTH);
+               SECURITY_DESCRIPTOR_MIN_LENGTH);
   if (descriptor == NULL)
     {
       PRINTLASTERROR("Failed to allocate descriptor.");
@@ -892,7 +893,7 @@
 write_selection_file (char **to_install, char **to_remove)
 {
   wchar_t *folder_name = NULL,
-          *path = NULL;
+           *path = NULL;
   HRESULT result = E_FAIL;
   HANDLE hFile = NULL;
   size_t path_len;

http://wald.intevation.org/projects/trustbridge/