]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
Revert "Move svc_status_string() out of rpc_client/cli_svcctl.c"
authorGünther Deschner <gd@samba.org>
Tue, 20 May 2008 09:32:05 +0000 (11:32 +0200)
committerGünther Deschner <gd@samba.org>
Tue, 20 May 2008 09:46:48 +0000 (11:46 +0200)
This reverts commit 2860ae2eb2cb99b4febb352f516b3fa9fbd2abbb.

source/rpc_client/cli_svcctl.c
source/utils/net_rpc_service.c

index 221dd60a352abb7e2e8b355a70176e7a93f7c552..b21909fd034dae5fcd4da0ea85d20e0f3b0ab019 100644 (file)
 #include "includes.h"
 #include "rpc_client.h"
 
+struct svc_state_msg {
+       uint32 flag;
+       const char *message;
+};
+
+static struct svc_state_msg state_msg_table[] = {
+       { SVCCTL_STOPPED,            "stopped" },
+       { SVCCTL_START_PENDING,      "start pending" },
+       { SVCCTL_STOP_PENDING,       "stop pending" },
+       { SVCCTL_RUNNING,            "running" },
+       { SVCCTL_CONTINUE_PENDING,   "resume pending" },
+       { SVCCTL_PAUSE_PENDING,      "pause pending" },
+       { SVCCTL_PAUSED,             "paused" },
+       { 0,                          NULL }
+};
+       
+
+/********************************************************************
+********************************************************************/
+const char* svc_status_string( uint32 state )
+{
+       fstring msg;
+       int i;
+       
+       fstr_sprintf( msg, "Unknown State [%d]", state );
+       
+       for ( i=0; state_msg_table[i].message; i++ ) {
+               if ( state_msg_table[i].flag == state ) {
+                       fstrcpy( msg, state_msg_table[i].message );
+                       break;  
+               }
+       }
+       
+       return talloc_strdup(talloc_tos(), msg);
+}
+
 /*******************************************************************
 *******************************************************************/
 
index 1b12bd311485a9dd5e40d4c4020a679d32ef9383..c4cc19eaa1cafbb77cc32bf2c369e3c5e1fe165a 100644 (file)
 #include "includes.h"
 #include "utils/net.h"
 
-
-struct svc_state_msg {
-       uint32 flag;
-       const char *message;
-};
-
-static struct svc_state_msg state_msg_table[] = {
-       { SVCCTL_STOPPED,            "stopped" },
-       { SVCCTL_START_PENDING,      "start pending" },
-       { SVCCTL_STOP_PENDING,       "stop pending" },
-       { SVCCTL_RUNNING,            "running" },
-       { SVCCTL_CONTINUE_PENDING,   "resume pending" },
-       { SVCCTL_PAUSE_PENDING,      "pause pending" },
-       { SVCCTL_PAUSED,             "paused" },
-       { 0,                          NULL }
-};
-
-
-/********************************************************************
-********************************************************************/
-const char *svc_status_string( uint32 state )
-{
-       fstring msg;
-       int i;
-
-       fstr_sprintf( msg, "Unknown State [%d]", state );
-
-       for ( i=0; state_msg_table[i].message; i++ ) {
-               if ( state_msg_table[i].flag == state ) {
-                       fstrcpy( msg, state_msg_table[i].message );
-                       break;
-               }
-       }
-
-       return talloc_strdup(talloc_tos(), msg);
-}
-
 /********************************************************************
 ********************************************************************/