rpms/nspluginwrapper/devel nspluginwrapper-0.9.91.4-rh.patch, 1.6, 1.7 nspluginwrapper.spec, 1.13, 1.14

Martin Stransky (stransky) fedora-extras-commits at redhat.com
Tue Aug 14 10:58:11 UTC 2007


Author: stransky

Update of /cvs/pkgs/rpms/nspluginwrapper/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv29362

Modified Files:
	nspluginwrapper-0.9.91.4-rh.patch nspluginwrapper.spec 
Log Message:
implemented plugin restart (#251530)

nspluginwrapper-0.9.91.4-rh.patch:

Index: nspluginwrapper-0.9.91.4-rh.patch
===================================================================
RCS file: /cvs/pkgs/rpms/nspluginwrapper/devel/nspluginwrapper-0.9.91.4-rh.patch,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- nspluginwrapper-0.9.91.4-rh.patch	10 Aug 2007 09:52:24 -0000	1.6
+++ nspluginwrapper-0.9.91.4-rh.patch	14 Aug 2007 10:58:08 -0000	1.7
@@ -1,5 +1,5 @@
 --- nspluginwrapper-0.9.91.4/Makefile.rh	2007-04-03 07:31:22.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/Makefile	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/Makefile	2007-08-14 12:36:19.000000000 +0200
 @@ -52,23 +52,6 @@ ifneq (,$(findstring $(OS),netbsd dragon
  X_LDFLAGS += -Wl,--rpath,$(x11prefix)/$(lib64)
  endif
@@ -235,7 +235,7 @@
  		-Wl,--version-script,$(patsubst $(LSB_OBJ_DIR)/%.o,$(LSB_SRC_DIR)/%.Version,$<) \
  		-Wl,-soname,`grep "$(patsubst $(LSB_OBJ_DIR)/%.o,%,$<) " $(LSB_SRC_DIR)/LibNameMap.txt | cut -f2 -d' '`
 --- nspluginwrapper-0.9.91.4/configure.rh	2007-04-02 23:42:24.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/configure	2007-08-10 10:59:17.000000000 +0200
++++ nspluginwrapper-0.9.91.4/configure	2007-08-14 12:36:19.000000000 +0200
 @@ -21,45 +21,18 @@ TMPS="${TMPDIR1}/npw-conf-${RANDOM}-$$-$
  
  # default parameters
@@ -652,7 +652,7 @@
 +echo "DONT_STRIP=yes" >> $config_mak
 +
 --- nspluginwrapper-0.9.91.4/src/npw-wrapper.c.rh	2007-04-02 21:52:57.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-wrapper.c	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-wrapper.c	2007-08-14 12:39:40.000000000 +0200
 @@ -42,6 +42,7 @@
  
  #include "rpc.h"
@@ -661,7 +661,25 @@
  #include "utils.h"
  
  #define XP_UNIX 1
-@@ -182,7 +183,7 @@ g_NPN_GetValue(NPP instance, NPNVariable
+@@ -84,6 +85,8 @@ typedef struct {
+ 
+ static Plugin g_plugin = { 0, -1, 0, NULL, NULL, NULL };
+ 
++static bool has_npruntime = true;
++
+ // Instance state information about the plugin
+ typedef struct _PluginInstance {
+   NPP instance;
+@@ -100,6 +103,8 @@ typedef struct _StreamInstance {
+ static void plugin_init(int is_NP_Initialize);
+ static void plugin_exit(void);
+ static pthread_mutex_t plugin_init_lock = PTHREAD_MUTEX_INITIALIZER;
++static NPError plugin_restart(void);
++static NPError check_restart(void);
+ 
+ // Helpers
+ #ifndef min
+@@ -182,7 +187,7 @@ g_NPN_GetValue(NPP instance, NPNVariable
    if (mozilla_funcs.getvalue == NULL)
  	return NPERR_INVALID_FUNCTABLE_ERROR;
  
@@ -670,7 +688,7 @@
    NPError ret = mozilla_funcs.getvalue(instance, variable, value);
    D(bug(" return: %d [%s]\n", ret, string_of_NPError(ret)));
    return ret;
-@@ -190,20 +191,20 @@ g_NPN_GetValue(NPP instance, NPNVariable
+@@ -190,20 +195,20 @@ g_NPN_GetValue(NPP instance, NPNVariable
  
  static int handle_NPN_GetValue(rpc_connection_t *connection)
  {
@@ -694,7 +712,7 @@
    NPError ret = NPERR_GENERIC_ERROR;
    switch (rpc_type_of_NPNVariable(variable)) {
    case RPC_TYPE_BOOLEAN:
-@@ -220,6 +221,7 @@ static int handle_NPN_GetValue(rpc_conne
+@@ -220,6 +225,7 @@ static int handle_NPN_GetValue(rpc_conne
  	}
    }
  
@@ -702,7 +720,41 @@
    abort();
  }
  
-@@ -1742,9 +1744,9 @@ static void do_plugin_init(int is_NP_Ini
+@@ -956,7 +962,12 @@ g_NPP_New(NPMIMEType mime_type, NPP inst
+ {
+   if (instance == NULL)
+ 	return NPERR_INVALID_INSTANCE_ERROR;
+-
++	
++  // Check if we need to restart the plug-in
++  NPError rt = check_restart();
++  if(rt != NPERR_NO_ERROR)
++  	return(rt);
++		
+   PluginInstance *plugin = malloc(sizeof(*plugin));
+   if (plugin == NULL)
+ 	return NPERR_OUT_OF_MEMORY_ERROR;
+@@ -1204,8 +1215,9 @@ invoke_NPP_URLNotify(NPP instance, const
+ 
+   error = rpc_method_wait_for_reply(g_rpc_connection, RPC_TYPE_INVALID);
+   
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
+ 	npw_perror("NPP_URLNotify() wait for reply", error);
++	}
+ }
+ 
+ static void
+@@ -1639,7 +1651,7 @@ NP_Initialize(NPNetscapeFuncs *moz_funcs
+ 	return NPERR_MODULE_LOAD_FAILED_ERROR;
+ 
+   // NPRuntime appeared in NPAPI >= 0.14
+-  bool has_npruntime = true;
++  has_npruntime = true;
+   if ((moz_funcs->version >> 8) == 0 && (moz_funcs->version & 0xff) < 14)
+ 	has_npruntime = false;
+   // check that the browser doesn't lie
+@@ -1742,9 +1754,9 @@ static void do_plugin_init(int is_NP_Ini
    static int init_count = 0;
    ++init_count;
    char viewer_path[PATH_MAX];
@@ -714,8 +766,68 @@
  
    // Cache MIME info and plugin name/description
    if (g_plugin.name == NULL && g_plugin.description == NULL && g_plugin.formats == NULL) {
---- /dev/null	2007-08-10 09:09:49.649070069 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-dir.c	2007-08-10 10:50:00.000000000 +0200
+@@ -1990,3 +2002,59 @@ static void __attribute__((destructor)) 
+ 	g_plugin.description = NULL;
+   }
+ }
++
++static NPError plugin_restart(void)
++{
++  if(!g_plugin.is_wrapper) {
++    D(bug("plugin restart\n"));
++
++    // Shut it down    
++    plugin_exit();
++
++    g_plugin.initialized = 0;
++    g_plugin.viewer_pid = -1;
++    g_plugin.is_wrapper = 0;
++
++    // And start it again
++    plugin_init(1);
++    if (g_plugin.initialized <= 0)
++			return NPERR_MODULE_LOAD_FAILED_ERROR;
++		
++		int error = rpc_method_invoke(g_rpc_connection,
++									RPC_METHOD_NP_INITIALIZE,
++									RPC_TYPE_UINT32, (uint32_t)has_npruntime,
++									RPC_TYPE_INVALID);
++	
++		if (error != RPC_ERROR_NO_ERROR) {
++		npw_perror("NP_Initialize() invoke", error);
++		return NPERR_MODULE_LOAD_FAILED_ERROR;
++		}
++	
++		int32_t ret;
++		error = rpc_method_wait_for_reply(g_rpc_connection, RPC_TYPE_INT32, &ret, RPC_TYPE_INVALID);
++	
++		if (error != RPC_ERROR_NO_ERROR) {
++		npw_perror("NP_Initialize() wait for reply", error);
++		return NPERR_MODULE_LOAD_FAILED_ERROR;
++		}
++	
++		D(bug(" return: %d [%s]\n", ret, string_of_NPError(ret)));
++		return ret;
++
++    return NPERR_NO_ERROR;
++  }
++}
++
++static NPError check_restart(void)
++{
++	if(get_network_status()) {
++		D(bug("Plugin restart\n"));
++		int ret = plugin_restart();
++		if(ret == NPERR_NO_ERROR) {			
++			clear_network_status();
++		}		
++		D(bug("check_restart return %d [%s]\n", ret, string_of_NPError(ret)));
++		return(ret);
++	}	
++	return(NPERR_NO_ERROR);
++}
+--- /dev/null	2007-08-14 10:11:09.632093891 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-dir.c	2007-08-14 12:36:19.000000000 +0200
 @@ -0,0 +1,97 @@
 +/*
 + *  npw-dir.h - Directory management for nspluginwrapper
@@ -814,8 +926,46 @@
 +  snprintf(p_path, max_path, "%s/%s/%d-%d", NPW_CONNECTION_PATH, p_plugin, getpid(), init_count);
 +  return(p_path);
 +}
+--- nspluginwrapper-0.9.91.4/src/utils.c.rh	2007-03-04 16:01:22.000000000 +0100
++++ nspluginwrapper-0.9.91.4/src/utils.c	2007-08-14 12:39:12.000000000 +0200
+@@ -171,6 +171,35 @@ const char *string_of_NPStreamType(int s
+ }
+ #endif
+ 
++/* ====================================================================== */
++/* === Network status                                                 === */
++/* ====================================================================== */
++
++#define ERROR_RPC(error)  ((error) > -1100 && (error) <= -1000)
++
++static int  network_error = FALSE;
++
++void check_network_error(int err_code)
++{
++	if(ERROR_RPC(err_code))
++		network_error = TRUE;
++}
++
++void set_network_error(void)
++{
++	network_error = TRUE;
++}
++
++int  get_network_status(void)
++{	
++	return(network_error);
++}
++
++void clear_network_status(void)
++{
++	network_error = FALSE;
++}
++
+ 
+ /* ====================================================================== */
+ /* === Misc utility functions                                         === */
 --- nspluginwrapper-0.9.91.4/src/debug.h.rh	2007-03-04 16:01:22.000000000 +0100
-+++ nspluginwrapper-0.9.91.4/src/debug.h	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/debug.h	2007-08-14 12:36:19.000000000 +0200
 @@ -29,7 +29,7 @@ extern void npw_printf(const char *forma
  extern void npw_vprintf(const char *format, va_list args) attribute_hidden;
  
@@ -826,7 +976,7 @@
  #else
  #define D(x) ;
 --- nspluginwrapper-0.9.91.4/src/sysdeps.h.rh	2007-03-04 16:01:22.000000000 +0100
-+++ nspluginwrapper-0.9.91.4/src/sysdeps.h	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/sysdeps.h	2007-08-14 12:36:19.000000000 +0200
 @@ -43,8 +43,8 @@
  #define NPW_VIEWER NPW_VIEWER_BASE
  #define NPW_WRAPPER_BASE "npwrapper"
@@ -838,8 +988,21 @@
  #define NPW_PLUGIN_IDENT "NPW:" NPW_VERSION
  #define NPW_PLUGIN_IDENT_SIZE 32
  typedef struct __attribute__((packed)) {
+--- nspluginwrapper-0.9.91.4/src/utils.h.rh	2007-03-04 16:01:22.000000000 +0100
++++ nspluginwrapper-0.9.91.4/src/utils.h	2007-08-14 12:39:29.000000000 +0200
+@@ -39,4 +39,10 @@ extern const char *string_of_NPStreamTyp
+ extern void npw_perror(const char *prefix, int error) attribute_hidden;
+ extern const char *npw_strerror(int error) attribute_hidden;
+ 
++// Network status
++void check_network_error(int err_code);
++int  get_network_status(void);
++void clear_network_status(void);
++void set_network_error(void);
++
+ #endif /* UTILS_H */
 --- nspluginwrapper-0.9.91.4/src/npw-viewer.c.rh	2007-04-02 21:52:57.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-viewer.c	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-viewer.c	2007-08-14 12:36:19.000000000 +0200
 @@ -53,10 +53,6 @@
  #define DEBUG 1
  #include "debug.h"
@@ -929,7 +1092,7 @@
    }
  
 --- nspluginwrapper-0.9.91.4/src/npw-viewer.sh.rh	2007-04-02 21:52:57.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-viewer.sh	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-viewer.sh	2007-08-14 12:36:19.000000000 +0200
 @@ -4,7 +4,13 @@
  #
  OS="`uname -s`"
@@ -1000,7 +1163,7 @@
  if test "$OS" = "NetBSD"; then
      REALPLAYER_HOME="/usr/pkg/lib/RealPlayer"
 --- nspluginwrapper-0.9.91.4/src/npw-rpc.c.rh	2007-04-02 21:52:57.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-rpc.c	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-rpc.c	2007-08-14 12:36:19.000000000 +0200
 @@ -49,6 +49,8 @@ int rpc_type_of_NPNVariable(int variable
    case NPNVSupportsXEmbedBool:
  	type = RPC_TYPE_BOOLEAN;
@@ -1010,8 +1173,8 @@
    case NPNVWindowNPObject:
    case NPNVPluginElementNPObject:
  	type = RPC_TYPE_NP_OBJECT;
---- /dev/null	2007-08-10 09:09:49.649070069 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-dir.h	2007-08-10 10:50:00.000000000 +0200
+--- /dev/null	2007-08-14 10:11:09.632093891 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-dir.h	2007-08-14 12:36:19.000000000 +0200
 @@ -0,0 +1,35 @@
 +/*
 + *  npw-dir.h - Directory management for nspluginwrapper
@@ -1049,7 +1212,7 @@
 +
 +#endif
 --- nspluginwrapper-0.9.91.4/src/npw-config.c.rh	2007-04-02 22:42:15.000000000 +0200
-+++ nspluginwrapper-0.9.91.4/src/npw-config.c	2007-08-10 10:50:00.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/npw-config.c	2007-08-14 12:36:19.000000000 +0200
 @@ -38,10 +38,15 @@
  #include <pwd.h>
  #include <dirent.h>
@@ -1747,3 +1910,248 @@
    }
  
    return 0;
+--- nspluginwrapper-0.9.91.4/src/rpc.c.rh	2007-04-02 22:03:07.000000000 +0200
++++ nspluginwrapper-0.9.91.4/src/rpc.c	2007-08-14 12:36:19.000000000 +0200
+@@ -1441,8 +1441,10 @@ int rpc_method_invoke(rpc_connection_t *
+ {
+   D(bug("rpc_method_invoke method=%d\n", method));
+ 
+-  if (connection == NULL)
++  if (connection == NULL) {
++	set_network_error();
+ 	return RPC_ERROR_CONNECTION_NULL;
++  }
+ 
+   rpc_message_t message;
+   rpc_message_init(&message, connection);
+@@ -1452,29 +1454,41 @@ int rpc_method_invoke(rpc_connection_t *
+ 	int ret = _rpc_wait_dispatch(connection, 0);
+ 	if (ret == 0)
+ 	  break;
+-	if (ret < 0 || (ret = rpc_dispatch(connection)) < 0)
++	if (ret < 0 || (ret = rpc_dispatch(connection)) < 0) {
++          check_network_error(ret);
+ 	  return ret;
++  	}
+   }
+ 
+   // send: <invoke> = MESSAGE_START <method-id> MESSAGE_END
+   int error = rpc_message_send_int32(&message, RPC_MESSAGE_START);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+   error = rpc_message_send_int32(&message, method);
+-  if (error != RPC_ERROR_NO_ERROR)
+-	return error;
++  if (error != RPC_ERROR_NO_ERROR) {
++        set_network_error();
++        return error;
++  }
+   error = rpc_message_send_int32(&message, RPC_MESSAGE_END);
+-  if (error != RPC_ERROR_NO_ERROR)
+-	return error;
++  if (error != RPC_ERROR_NO_ERROR) {
++        set_network_error();
++        return error;
++  }
+   error = rpc_message_flush(&message);
+-  if (error != RPC_ERROR_NO_ERROR)
+-	return error;
++  if (error != RPC_ERROR_NO_ERROR) {
++        set_network_error();
++        return error;
++  }
+ 
+   // wait: MESSAGE_ACK
+   int32_t msg_tag;
+   error = rpc_message_recv_int32(&message, &msg_tag);
+-  if (error != RPC_ERROR_NO_ERROR)
+-	return error;
++  if (error != RPC_ERROR_NO_ERROR) {
++        set_network_error();
++        return error;
++  }
+   if (msg_tag != RPC_MESSAGE_ACK)
+ 	return RPC_ERROR_MESSAGE_TYPE_INVALID;
+ 
+@@ -1489,16 +1503,22 @@ int rpc_method_invoke(rpc_connection_t *
+ 	va_start(args, method);
+ 	error = rpc_message_send_args(&message, args);
+ 	va_end(args);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++        }
+ 	error = rpc_message_flush(&message);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 
+ 	// wait: MESSAGE_ACK
+ 	error = rpc_message_recv_int32(&message, &msg_tag);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 	if (msg_tag != RPC_MESSAGE_ACK)
+ 	  return RPC_ERROR_MESSAGE_TYPE_INVALID;
+   }
+@@ -1522,16 +1542,22 @@ int rpc_method_get_args(rpc_connection_t
+   va_start(args, connection);
+   int error = rpc_message_recv_args(&message, args);
+   va_end(args);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+ 
+   // send: MESSAGE_ACK
+   error = rpc_message_send_int32(&message, RPC_MESSAGE_ACK);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+   error = rpc_message_flush(&message);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+ 
+   return RPC_ERROR_NO_ERROR;
+ }
+@@ -1545,8 +1571,10 @@ int rpc_method_wait_for_reply(rpc_connec
+   va_list args;
+   rpc_message_t message;
+ 
+-  if (connection == NULL)
++  if (connection == NULL) {
++	set_network_error();
+ 	return RPC_ERROR_CONNECTION_NULL;
++  }
+ 
+   rpc_message_init(&message, connection);
+   va_start(args, connection);
+@@ -1558,12 +1586,16 @@ int rpc_method_wait_for_reply(rpc_connec
+   bool done = false;
+   while (!done) {
+ 	error = rpc_message_recv_int32(&message, &msg_tag);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 	switch (msg_tag) {
+ 	case RPC_MESSAGE_START:
+-	  if ((error = _rpc_dispatch(connection, &message)) < 0)
++	  if ((error = _rpc_dispatch(connection, &message)) < 0) {
++		set_network_error();
+ 		return error;
++	  }
+ 	  break;
+ 	case RPC_MESSAGE_REPLY:
+ 	case RPC_MESSAGE_ACK:
+@@ -1574,8 +1606,10 @@ int rpc_method_wait_for_reply(rpc_connec
+ 		// wait: <error-code>
+ 		int32_t error_code;
+ 		error = rpc_message_recv_int32(&message, &error_code);
+-		if (error != RPC_ERROR_NO_ERROR)
++		if (error != RPC_ERROR_NO_ERROR) {
++		  set_network_error();
+ 		  return error;
++		}
+ 		return error_code;
+ 	  }
+ 	default:
+@@ -1591,26 +1625,36 @@ int rpc_method_wait_for_reply(rpc_connec
+ 	va_start(args, connection);
+ 	error = rpc_message_recv_args(&message, args);
+ 	va_end(args);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 	error = rpc_message_recv_int32(&message, &msg_tag);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 	if (msg_tag != RPC_MESSAGE_END)
+ 	  return RPC_ERROR_MESSAGE_TYPE_INVALID;
+ 
+ 	// send: MESSAGE_ACK
+ 	error = rpc_message_send_int32(&message, RPC_MESSAGE_ACK);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 	error = rpc_message_flush(&message);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+ 
+ 	// wait: MESSAGE_ACK (prepare for final ACK)
+ 	error = rpc_message_recv_int32(&message, &msg_tag);
+-	if (error != RPC_ERROR_NO_ERROR)
++	if (error != RPC_ERROR_NO_ERROR) {
++	  set_network_error();
+ 	  return error;
++	}
+   }
+ 
+   // wait: MESSAGE_ACK
+@@ -1633,26 +1677,36 @@ int rpc_method_send_reply(rpc_connection
+ 
+   // send: <reply> = MESSAGE_REPLY [ <method-args> ] MESSAGE_END
+   int error = rpc_message_send_int32(&message, RPC_MESSAGE_REPLY);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+   va_list args;
+   va_start(args, connection);
+   error = rpc_message_send_args(&message, args);
+   va_end(args);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+   error = rpc_message_send_int32(&message, RPC_MESSAGE_END);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+   error = rpc_message_flush(&message);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+ 
+   // wait: MESSAGE_ACK
+   int32_t msg_tag;
+   error = rpc_message_recv_int32(&message, &msg_tag);
+-  if (error != RPC_ERROR_NO_ERROR)
++  if (error != RPC_ERROR_NO_ERROR) {
++	set_network_error();
+ 	return error;
++  }
+   if (msg_tag != RPC_MESSAGE_ACK)
+ 	return RPC_ERROR_MESSAGE_TYPE_INVALID;
+ 


Index: nspluginwrapper.spec
===================================================================
RCS file: /cvs/pkgs/rpms/nspluginwrapper/devel/nspluginwrapper.spec,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- nspluginwrapper.spec	14 Aug 2007 08:38:19 -0000	1.13
+++ nspluginwrapper.spec	14 Aug 2007 10:58:08 -0000	1.14
@@ -70,7 +70,7 @@
 Summary:	A compatibility layer for Netscape 4 plugins
 Name:		nspluginwrapper
 Version:	0.9.91.4
-Release:	17%{?dist}
+Release:	18%{?dist}
 Source0:	%{name}-%{version}%{?svndate:-%{svndate}}.tar.bz2
 Source1:        %{plugin_config_name}.tar.gz 
 Source2:        plugin-config.sh.in
@@ -219,6 +219,9 @@
 %{_sysconfdir}/sysconfig/%{name}
 
 %changelog
+* Tue Aug 14 2007 Martin Stransky <stransky at redhat.com> 0.9.91.4-18
+- implemented plugin restart (#251530)
+
 * Tue Aug 14 2007 Martin Stransky <stransky at redhat.com> 0.9.91.4-17
 - fixed an installation script (#251698)
 




More information about the fedora-extras-commits mailing list