Permalink
Browse files

moved notify module to the end of config & added auto_push checks to …

…notifier
  • Loading branch information...
1 parent 2ae585d commit 067c73710d15f046945ada24d5ca25d50b2751c7 @arut arut committed Sep 6, 2012
Showing with 10 additions and 2 deletions.
  1. +2 −2 config
  2. +8 −0 ngx_rtmp_notify_module.c
View
4 config
@@ -11,11 +11,11 @@ CORE_MODULES="$CORE_MODULES
ngx_rtmp_mp4_module \
ngx_rtmp_record_module \
ngx_rtmp_netcall_module \
- ngx_rtmp_notify_module \
ngx_rtmp_relay_module \
ngx_rtmp_exec_module \
ngx_rtmp_codec_module \
ngx_rtmp_auto_push_module \
+ ngx_rtmp_notify_module \
"
@@ -42,13 +42,13 @@ NGX_ADDON_SRCS="$NGX_ADDON_SRCS \
$ngx_addon_dir/ngx_rtmp_mp4_module.c \
$ngx_addon_dir/ngx_rtmp_record_module.c \
$ngx_addon_dir/ngx_rtmp_netcall_module.c \
- $ngx_addon_dir/ngx_rtmp_notify_module.c \
$ngx_addon_dir/ngx_rtmp_stat_module.c \
$ngx_addon_dir/ngx_rtmp_relay_module.c \
$ngx_addon_dir/ngx_rtmp_bandwidth.c \
$ngx_addon_dir/ngx_rtmp_exec_module.c \
$ngx_addon_dir/ngx_rtmp_codec_module.c \
$ngx_addon_dir/ngx_rtmp_auto_push_module.c \
+ $ngx_addon_dir/ngx_rtmp_notify_module.c \
"
CFLAGS="$CFLAGS -I$ngx_addon_dir"
View
@@ -528,6 +528,10 @@ ngx_rtmp_notify_play(ngx_rtmp_session_t *s, ngx_rtmp_play_t *v)
ngx_rtmp_notify_app_conf_t *nacf;
ngx_rtmp_netcall_init_t ci;
+ if (s->auto_pushed) {
+ goto next;
+ }
+
nacf = ngx_rtmp_get_module_app_conf(s, ngx_rtmp_notify_module);
if (nacf == NULL) {
@@ -565,6 +569,10 @@ ngx_rtmp_notify_delete_stream(ngx_rtmp_session_t *s, ngx_rtmp_delete_stream_t
ngx_rtmp_notify_ctx_t *ctx;
ngx_rtmp_notify_app_conf_t *nacf;
+ if (s->auto_pushed) {
+ goto next;
+ }
+
ctx = ngx_rtmp_get_module_ctx(s, ngx_rtmp_notify_module);
if (ctx == NULL) {

0 comments on commit 067c737

Please sign in to comment.