asterisk/asterisk.patch

changeset 404
b6420eee9bde
parent 398
08f5eb82b58f
child 405
375c04ff28ba
equal deleted inserted replaced
7:b04f8acf4558 8:fcf5f27b7aea
262 - ast_build_string(&t, &left, "{%s:%s/imap", imapserver, imapport); 262 - ast_build_string(&t, &left, "{%s:%s/imap", imapserver, imapport);
263 + ast_build_string(&t, &left, "{%s:%s", imapserver, imapport); 263 + ast_build_string(&t, &left, "{%s:%s", imapserver, imapport);
264 264
265 /* Add authentication user if present */ 265 /* Add authentication user if present */
266 if (!ast_strlen_zero(authuser)) 266 if (!ast_strlen_zero(authuser))
267 @@ -6174,6 +6175,7 @@ 267 @@ -6176,6 +6177,7 @@
268 /* simple. huh? */ 268 /* simple. huh? */
269 char sequence[10]; 269 char sequence[10];
270 char mailbox[256]; 270 char mailbox[256];
271 + char folder[256]; 271 + char folder[256];
272 int res; 272 int res;
273 273
274 /* get the real IMAP message number for this message */ 274 /* get the real IMAP message number for this message */
275 @@ -6189,10 +6191,24 @@ 275 @@ -6191,10 +6193,24 @@
276 mail_setflag(vms->mailstream, sequence, "\\Unseen"); 276 mail_setflag(vms->mailstream, sequence, "\\Unseen");
277 mail_clearflag(vms->mailstream, sequence, "\\Seen"); 277 mail_clearflag(vms->mailstream, sequence, "\\Seen");
278 } 278 }
279 - if (!strcasecmp(mbox(vmu, NEW_FOLDER), vms->curbox) && (box == NEW_FOLDER || box == OLD_FOLDER)) { 279 - if (!strcasecmp(mbox(vmu, NEW_FOLDER), vms->curbox) && (box == NEW_FOLDER || box == OLD_FOLDER)) {
280 - ast_mutex_unlock(&vms->lock); 280 - ast_mutex_unlock(&vms->lock);
297 } 297 }
298 + 298 +
299 /* Create the folder if it don't exist */ 299 /* Create the folder if it don't exist */
300 imap_mailbox_name(mailbox, sizeof(mailbox), vms, box, 1); /* Get the full mailbox name */ 300 imap_mailbox_name(mailbox, sizeof(mailbox), vms, box, 1); /* Get the full mailbox name */
301 ast_debug(5, "Checking if folder exists: %s\n", mailbox); 301 ast_debug(5, "Checking if folder exists: %s\n", mailbox);
302 @@ -10467,6 +10483,10 @@ 302 @@ -10469,6 +10485,10 @@
303 #ifndef IMAP_STORAGE 303 #ifndef IMAP_STORAGE
304 } else if (!cmd) { 304 } else if (!cmd) {
305 vms.deleted[vms.curmsg] = 1; 305 vms.deleted[vms.curmsg] = 1;
306 +#else 306 +#else
307 + } else if (!cmd && (folder_int(vms.curbox) > 1 || box > 1)) { 307 + } else if (!cmd && (folder_int(vms.curbox) > 1 || box > 1)) {
308 + vms.deleted[vms.curmsg] = 1; /* Enforce deletion after */ 308 + vms.deleted[vms.curmsg] = 1; /* Enforce deletion after */
309 + deleted = 1; /* successful copy op */ 309 + deleted = 1; /* successful copy op */
310 #endif 310 #endif
311 } else { 311 } else {
312 vms.deleted[vms.curmsg] = 0; 312 vms.deleted[vms.curmsg] = 0;
313 @@ -11963,6 +11983,15 @@ 313 @@ -11965,6 +11985,15 @@
314 } else { 314 } else {
315 ast_copy_string(imapfolder, "INBOX", sizeof(imapfolder)); 315 ast_copy_string(imapfolder, "INBOX", sizeof(imapfolder));
316 } 316 }
317 + /* IMAP saved (sub)folder location policy */ 317 + /* IMAP saved (sub)folder location policy */
318 + if ((val = ast_variable_retrieve(cfg, "general", "imapsubfold"))) { 318 + if ((val = ast_variable_retrieve(cfg, "general", "imapsubfold"))) {
752 endif 752 endif
753 Index: channels/chan_sip.c 753 Index: channels/chan_sip.c
754 diff -Nau channels/chan_sip.c.orig channels/chan_sip.c 754 diff -Nau channels/chan_sip.c.orig channels/chan_sip.c
755 --- channels/chan_sip.c.orig 2011-08-10 00:12:59.000000000 +0200 755 --- channels/chan_sip.c.orig 2011-08-10 00:12:59.000000000 +0200
756 +++ channels/chan_sip.c 2011-09-14 14:29:50.757959000 +0200 756 +++ channels/chan_sip.c 2011-09-14 14:29:50.757959000 +0200
757 @@ -11650,7 +11650,16 @@ 757 @@ -11676,7 +11676,16 @@
758 } else { 758 } else {
759 if (sipmethod == SIP_NOTIFY && !ast_strlen_zero(p->theirtag)) { 759 if (sipmethod == SIP_NOTIFY && !ast_strlen_zero(p->theirtag)) {
760 /* If this is a NOTIFY, use the From: tag in the subscribe (RFC 3265) */ 760 /* If this is a NOTIFY, use the From: tag in the subscribe (RFC 3265) */
761 - snprintf(to, sizeof(to), "<%s%s>;tag=%s", (strncasecmp(p->uri, "sip:", 4) ? "sip:" : ""), p->uri, p->theirtag); 761 - snprintf(to, sizeof(to), "<%s%s>;tag=%s", (strncasecmp(p->uri, "sip:", 4) ? "sip:" : ""), p->uri, p->theirtag);
762 + if (strncasecmp(p->uri, "sip:", strlen("sip:"))) 762 + if (strncasecmp(p->uri, "sip:", strlen("sip:")))
790 "console {videodevice|videocodec" \ 790 "console {videodevice|videocodec" \
791 Index: configure 791 Index: configure
792 diff -Nau configure.orig configure 792 diff -Nau configure.orig configure
793 --- configure.orig 2011-08-25 21:08:04.000000000 +0200 793 --- configure.orig 2011-08-25 21:08:04.000000000 +0200
794 +++ configure 2011-09-14 14:29:50.767970949 +0200 794 +++ configure 2011-09-14 14:29:50.767970949 +0200
795 @@ -4244,11 +4244,6 @@ 795 @@ -4447,11 +4447,6 @@
796 esac 796 esac
797 797
798 case "${host_os}" in 798 case "${host_os}" in
799 - freebsd*) 799 - freebsd*)
800 - ac_default_prefix=/usr/local 800 - ac_default_prefix=/usr/local
802 - LDFLAGS=-L/usr/local/lib 802 - LDFLAGS=-L/usr/local/lib
803 - ;; 803 - ;;
804 openbsd*) 804 openbsd*)
805 ac_default_prefix=/usr/local 805 ac_default_prefix=/usr/local
806 if test ${prefix} = '/usr/local' || test ${prefix} = 'NONE'; then 806 if test ${prefix} = '/usr/local' || test ${prefix} = 'NONE'; then
807 @@ -29617,8 +29612,8 @@ 807 @@ -31424,8 +31419,8 @@
808 if test -f "${IMAP_TK_DIR}/c-client/LDFLAGS"; then 808 if test -f "${IMAP_TK_DIR}/c-client/LDFLAGS"; then
809 imap_ldflags=`cat ${IMAP_TK_DIR}/c-client/LDFLAGS` 809 imap_ldflags=`cat ${IMAP_TK_DIR}/c-client/LDFLAGS`
810 fi 810 fi
811 - imap_libs="${IMAP_TK_DIR}/c-client/c-client.a" 811 - imap_libs="${IMAP_TK_DIR}/c-client/c-client.a"
812 - imap_include="-I${IMAP_TK_DIR}/c-client" 812 - imap_include="-I${IMAP_TK_DIR}/c-client"
813 + imap_libs="-limap -lssl -lcrypto -lcrypt" 813 + imap_libs="-limap -lssl -lcrypto -lcrypt"
814 + imap_include="-DUSE_SYSTEM_IMAP -I${IMAP_TK_DIR}/include/imap" 814 + imap_include="-DUSE_SYSTEM_IMAP -I${IMAP_TK_DIR}/include/imap"
815 CPPFLAGS="${CPPFLAGS} ${imap_include}" 815 CPPFLAGS="${CPPFLAGS} ${imap_include}"
816 LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}` 816 LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
817 cat >conftest.$ac_ext <<_ACEOF 817 cat >conftest.$ac_ext <<_ACEOF
818 @@ -47493,7 +47488,7 @@ 818 @@ -49375,7 +49370,7 @@
819 pbxlibdir="-L${SQLITE_DIR}" 819 pbxlibdir="-L${SQLITE_DIR}"
820 fi 820 fi
821 fi 821 fi
822 - pbxfuncname="sqlite_exec" 822 - pbxfuncname="sqlite_exec"
823 + pbxfuncname="sqlite3_exec" 823 + pbxfuncname="sqlite3_exec"
824 if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers 824 if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
825 AST_SQLITE_FOUND=yes 825 AST_SQLITE_FOUND=yes
826 else 826 else
827 @@ -49185,16 +49180,16 @@ 827 @@ -51127,16 +51122,16 @@
828 if test "x${PBX_GMIME}" != "x1" -a "${USE_GMIME}" != "no"; then 828 if test "x${PBX_GMIME}" != "x1" -a "${USE_GMIME}" != "no"; then
829 PBX_GMIME=0 829 PBX_GMIME=0
830 if test -n "$ac_tool_prefix"; then 830 if test -n "$ac_tool_prefix"; then
831 - # Extract the first word of "${ac_tool_prefix}gmime-config", so it can be a program name with args. 831 - # Extract the first word of "${ac_tool_prefix}gmime-config", so it can be a program name with args.
832 -set dummy ${ac_tool_prefix}gmime-config; ac_word=$2 832 -set dummy ${ac_tool_prefix}gmime-config; ac_word=$2
833 + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 833 + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
834 +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 834 +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
835 { echo "$as_me:$LINENO: checking for $ac_word" >&5 835 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
836 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } 836 $as_echo_n "checking for $ac_word... " >&6; }
837 -if test "${ac_cv_path_CONFIG_GMIME+set}" = set; then 837 -if test "${ac_cv_path_CONFIG_GMIME+set}" = set; then
838 +if test "${ac_cv_path_PKGCONFIG+set}" = set; then 838 +if test "${ac_cv_path_PKGCONFIG+set}" = set; then
839 echo $ECHO_N "(cached) $ECHO_C" >&6 839 $as_echo_n "(cached) " >&6
840 else 840 else
841 - case $CONFIG_GMIME in 841 - case $CONFIG_GMIME in
842 + case $PKGCONFIG in 842 + case $PKGCONFIG in
843 [\\/]* | ?:[\\/]*) 843 [\\/]* | ?:[\\/]*)
844 - ac_cv_path_CONFIG_GMIME="$CONFIG_GMIME" # Let the user override the test with a path. 844 - ac_cv_path_CONFIG_GMIME="$CONFIG_GMIME" # Let the user override the test with a path.
845 + ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path. 845 + ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
846 ;; 846 ;;
847 *) 847 *)
848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
849 @@ -49205,7 +49200,7 @@ 849 @@ -51147,7 +51142,7 @@
850 test -z "$as_dir" && as_dir=. 850 test -z "$as_dir" && as_dir=.
851 for ac_exec_ext in '' $ac_executable_extensions; do 851 for ac_exec_ext in '' $ac_executable_extensions; do
852 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 852 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
853 - ac_cv_path_CONFIG_GMIME="$as_dir/$ac_word$ac_exec_ext" 853 - ac_cv_path_CONFIG_GMIME="$as_dir/$ac_word$ac_exec_ext"
854 + ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext" 854 + ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
855 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 855 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
856 break 2 856 break 2
857 fi 857 fi
858 @@ -49216,10 +49211,10 @@ 858 @@ -51158,10 +51153,10 @@
859 ;; 859 ;;
860 esac 860 esac
861 fi 861 fi
862 -CONFIG_GMIME=$ac_cv_path_CONFIG_GMIME 862 -CONFIG_GMIME=$ac_cv_path_CONFIG_GMIME
863 -if test -n "$CONFIG_GMIME"; then 863 -if test -n "$CONFIG_GMIME"; then
864 - { echo "$as_me:$LINENO: result: $CONFIG_GMIME" >&5 864 - { $as_echo "$as_me:$LINENO: result: $CONFIG_GMIME" >&5
865 -echo "${ECHO_T}$CONFIG_GMIME" >&6; } 865 -$as_echo "$CONFIG_GMIME" >&6; }
866 +PKGCONFIG=$ac_cv_path_PKGCONFIG 866 +PKGCONFIG=$ac_cv_path_PKGCONFIG
867 +if test -n "$PKGCONFIG"; then 867 +if test -n "$PKGCONFIG"; then
868 + { echo "$as_me:$LINENO: result: $PKGCONFIG" >&5 868 + { $as_echo "$as_me:$LINENO: result: $PKGCONFIG" >&5
869 +echo "${ECHO_T}$PKGCONFIG" >&6; } 869 +$as_echo "$PKGCONFIG" >&6; }
870 else 870 else
871 { echo "$as_me:$LINENO: result: no" >&5 871 { $as_echo "$as_me:$LINENO: result: no" >&5
872 echo "${ECHO_T}no" >&6; } 872 $as_echo "no" >&6; }
873 @@ -49227,18 +49222,18 @@ 873 @@ -51169,18 +51164,18 @@
874 874
875 875
876 fi 876 fi
877 -if test -z "$ac_cv_path_CONFIG_GMIME"; then 877 -if test -z "$ac_cv_path_CONFIG_GMIME"; then
878 - ac_pt_CONFIG_GMIME=$CONFIG_GMIME 878 - ac_pt_CONFIG_GMIME=$CONFIG_GMIME
879 - # Extract the first word of "gmime-config", so it can be a program name with args.
880 -set dummy gmime-config; ac_word=$2
881 +if test -z "$ac_cv_path_PKGCONFIG"; then 879 +if test -z "$ac_cv_path_PKGCONFIG"; then
882 + ac_pt_PKGCONFIG=$PKGCONFIG 880 + ac_pt_PKGCONFIG=$PKGCONFIG
883 + # Extract the first word of "pkg-config", so it can be a program name with args. 881 # Extract the first word of "gmime-config", so it can be a program name with args.
882 -set dummy gmime-config; ac_word=$2
884 +set dummy pkg-config; ac_word=$2 883 +set dummy pkg-config; ac_word=$2
885 { echo "$as_me:$LINENO: checking for $ac_word" >&5 884 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
886 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } 885 $as_echo_n "checking for $ac_word... " >&6; }
887 -if test "${ac_cv_path_ac_pt_CONFIG_GMIME+set}" = set; then 886 -if test "${ac_cv_path_ac_pt_CONFIG_GMIME+set}" = set; then
888 +if test "${ac_cv_path_ac_pt_PKGCONFIG+set}" = set; then 887 +if test "${ac_cv_path_ac_pt_PKGCONFIG+set}" = set; then
889 echo $ECHO_N "(cached) $ECHO_C" >&6 888 $as_echo_n "(cached) " >&6
890 else 889 else
891 - case $ac_pt_CONFIG_GMIME in 890 - case $ac_pt_CONFIG_GMIME in
892 + case $ac_pt_PKGCONFIG in 891 + case $ac_pt_PKGCONFIG in
893 [\\/]* | ?:[\\/]*) 892 [\\/]* | ?:[\\/]*)
894 - ac_cv_path_ac_pt_CONFIG_GMIME="$ac_pt_CONFIG_GMIME" # Let the user override the test with a path. 893 - ac_cv_path_ac_pt_CONFIG_GMIME="$ac_pt_CONFIG_GMIME" # Let the user override the test with a path.
895 + ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path. 894 + ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
896 ;; 895 ;;
897 *) 896 *)
898 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 897 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
899 @@ -49249,7 +49244,7 @@ 898 @@ -51191,7 +51186,7 @@
900 test -z "$as_dir" && as_dir=. 899 test -z "$as_dir" && as_dir=.
901 for ac_exec_ext in '' $ac_executable_extensions; do 900 for ac_exec_ext in '' $ac_executable_extensions; do
902 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 901 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
903 - ac_cv_path_ac_pt_CONFIG_GMIME="$as_dir/$ac_word$ac_exec_ext" 902 - ac_cv_path_ac_pt_CONFIG_GMIME="$as_dir/$ac_word$ac_exec_ext"
904 + ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext" 903 + ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
905 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 904 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
906 break 2 905 break 2
907 fi 906 fi
908 @@ -49260,17 +49255,17 @@ 907 @@ -51202,17 +51197,17 @@
909 ;; 908 ;;
910 esac 909 esac
911 fi 910 fi
912 -ac_pt_CONFIG_GMIME=$ac_cv_path_ac_pt_CONFIG_GMIME 911 -ac_pt_CONFIG_GMIME=$ac_cv_path_ac_pt_CONFIG_GMIME
913 -if test -n "$ac_pt_CONFIG_GMIME"; then 912 -if test -n "$ac_pt_CONFIG_GMIME"; then
914 - { echo "$as_me:$LINENO: result: $ac_pt_CONFIG_GMIME" >&5 913 - { $as_echo "$as_me:$LINENO: result: $ac_pt_CONFIG_GMIME" >&5
915 -echo "${ECHO_T}$ac_pt_CONFIG_GMIME" >&6; } 914 -$as_echo "$ac_pt_CONFIG_GMIME" >&6; }
916 +ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG 915 +ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
917 +if test -n "$ac_pt_PKGCONFIG"; then 916 +if test -n "$ac_pt_PKGCONFIG"; then
918 + { echo "$as_me:$LINENO: result: $ac_pt_PKGCONFIG" >&5 917 + { $as_echo "$as_me:$LINENO: result: $ac_pt_PKGCONFIG" >&5
919 +echo "${ECHO_T}$ac_pt_PKGCONFIG" >&6; } 918 +$as_echo "$ac_pt_PKGCONFIG" >&6; }
920 else 919 else
921 { echo "$as_me:$LINENO: result: no" >&5 920 { $as_echo "$as_me:$LINENO: result: no" >&5
922 echo "${ECHO_T}no" >&6; } 921 $as_echo "no" >&6; }
923 fi 922 fi
924 923
925 - if test "x$ac_pt_CONFIG_GMIME" = x; then 924 - if test "x$ac_pt_CONFIG_GMIME" = x; then
926 - CONFIG_GMIME="No" 925 - CONFIG_GMIME="No"
927 + if test "x$ac_pt_PKGCONFIG" = x; then 926 + if test "x$ac_pt_PKGCONFIG" = x; then
928 + PKGCONFIG="No" 927 + PKGCONFIG="No"
929 else 928 else
930 case $cross_compiling:$ac_tool_warned in 929 case $cross_compiling:$ac_tool_warned in
931 yes:) 930 yes:)
932 @@ -49282,22 +49277,17 @@ 931 @@ -51220,22 +51215,17 @@
933 configuration is useful to you, please write to autoconf@gnu.org." >&2;} 932 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
934 ac_tool_warned=yes ;; 933 ac_tool_warned=yes ;;
935 esac 934 esac
936 - CONFIG_GMIME=$ac_pt_CONFIG_GMIME 935 - CONFIG_GMIME=$ac_pt_CONFIG_GMIME
937 + PKGCONFIG=$ac_pt_PKGCONFIG 936 + PKGCONFIG=$ac_pt_PKGCONFIG
938 fi 937 fi
1022 /* 1021 /*
1023 Index: main/features.c 1022 Index: main/features.c
1024 diff -Nau main/features.c.orig main/features.c 1023 diff -Nau main/features.c.orig main/features.c
1025 --- main/features.c.orig 2011-08-10 00:12:59.000000000 +0200 1024 --- main/features.c.orig 2011-08-10 00:12:59.000000000 +0200
1026 +++ main/features.c 2011-09-14 14:29:50.777958246 +0200 1025 +++ main/features.c 2011-09-14 14:29:50.777958246 +0200
1027 @@ -1922,6 +1922,10 @@ 1026 @@ -1928,6 +1928,10 @@
1028 snprintf(args, len, "%s,%s,m", S_OR(touch_format, "wav"), touch_filename); 1027 snprintf(args, len, "%s,%s,m", S_OR(touch_format, "wav"), touch_filename);
1029 } 1028 }
1030 1029
1031 + for(x = 0; x < strlen(touch_filename); x++) { 1030 + for(x = 0; x < strlen(touch_filename); x++) {
1032 + if (args[x] == '/') 1031 + if (args[x] == '/')
1033 + args[x] = '-'; 1032 + args[x] = '-';
1034 + } 1033 + }
1035 for(x = 0; x < strlen(args); x++) { 1034 for(x = 0; x < strlen(args); x++) {
1036 if (args[x] == '/') 1035 if (args[x] == '/')
1037 args[x] = '-'; 1036 args[x] = '-';
1038 @@ -2038,6 +2042,10 @@ 1037 @@ -2044,6 +2048,10 @@
1039 snprintf(args, len, "%s.%s,b", touch_filename, S_OR(touch_format, "wav")); 1038 snprintf(args, len, "%s.%s,b", touch_filename, S_OR(touch_format, "wav"));
1040 } 1039 }
1041 1040
1042 + for( x = 0; x < strlen(touch_filename); x++) { 1041 + for( x = 0; x < strlen(touch_filename); x++) {
1043 + if (args[x] == '/') 1042 + if (args[x] == '/')

mercurial