gstreamer-register will now never cause the
Original commit message from CVS: gstreamer-register will now never cause the ** WARNING **: gstplugin: registry needs rebuild warning to appear - sets a hidden global in gstplugin.c to turn the warning off. Fix a warning in gst/cothreads.c (function was declared extern, defined static)
This commit is contained in:
parent
ee7ae65e60
commit
e89f87b6b4
@ -159,7 +159,7 @@ cothread_setfunc (cothread_state *thread,
|
|||||||
*
|
*
|
||||||
* Returns: the #cothread_state of the main (0th) thread
|
* Returns: the #cothread_state of the main (0th) thread
|
||||||
*/
|
*/
|
||||||
static cothread_state*
|
cothread_state*
|
||||||
cothread_main(cothread_context *ctx)
|
cothread_main(cothread_context *ctx)
|
||||||
{
|
{
|
||||||
GST_DEBUG (0,"returning %p, the 0th cothread\n",ctx->threads[0]);
|
GST_DEBUG (0,"returning %p, the 0th cothread\n",ctx->threads[0]);
|
||||||
|
@ -47,6 +47,10 @@ gint _gst_libraries_seqno;
|
|||||||
/* whether or not to spew library load issues */
|
/* whether or not to spew library load issues */
|
||||||
gboolean _gst_plugin_spew = FALSE;
|
gboolean _gst_plugin_spew = FALSE;
|
||||||
|
|
||||||
|
/* whether or not to warn if registry needs rebuild (gstreamer-register sets
|
||||||
|
* this to false.) */
|
||||||
|
gboolean _gst_warn_old_registry = TRUE;
|
||||||
|
|
||||||
static gboolean plugin_times_older_than(time_t regtime);
|
static gboolean plugin_times_older_than(time_t regtime);
|
||||||
static time_t get_time(const char * path);
|
static time_t get_time(const char * path);
|
||||||
|
|
||||||
@ -85,6 +89,7 @@ _gst_plugin_initialize (void)
|
|||||||
|
|
||||||
if (!doc || strcmp (doc->root->name, "GST-PluginRegistry") ||
|
if (!doc || strcmp (doc->root->name, "GST-PluginRegistry") ||
|
||||||
!plugin_times_older_than(get_time(GST_CONFIG_DIR"/reg.xml"))) {
|
!plugin_times_older_than(get_time(GST_CONFIG_DIR"/reg.xml"))) {
|
||||||
|
if (_gst_warn_old_registry)
|
||||||
g_warning ("gstplugin: registry needs rebuild\n");
|
g_warning ("gstplugin: registry needs rebuild\n");
|
||||||
gst_plugin_load_all ();
|
gst_plugin_load_all ();
|
||||||
return;
|
return;
|
||||||
|
@ -38,6 +38,7 @@
|
|||||||
#define GLOBAL_REGISTRY_FILE_TMP GLOBAL_REGISTRY_DIR"/.reg.xml.tmp"
|
#define GLOBAL_REGISTRY_FILE_TMP GLOBAL_REGISTRY_DIR"/.reg.xml.tmp"
|
||||||
|
|
||||||
extern gboolean _gst_plugin_spew;
|
extern gboolean _gst_plugin_spew;
|
||||||
|
extern gboolean _gst_warn_old_registry;
|
||||||
|
|
||||||
static void error_perm() {
|
static void error_perm() {
|
||||||
g_print("\n(%s)\n"
|
g_print("\n(%s)\n"
|
||||||
@ -103,6 +104,7 @@ int main(int argc,char *argv[])
|
|||||||
|
|
||||||
// Init gst
|
// Init gst
|
||||||
_gst_plugin_spew = TRUE;
|
_gst_plugin_spew = TRUE;
|
||||||
|
_gst_warn_old_registry = FALSE;
|
||||||
gst_init(&argc,&argv);
|
gst_init(&argc,&argv);
|
||||||
|
|
||||||
// Check args
|
// Check args
|
||||||
|
Loading…
x
Reference in New Issue
Block a user