Mercurial > hg > xemacs-beta
comparison src/tooltalk.c @ 4834:b3ea9c582280
Use new cygwin_conv_path API with Cygwin 1.7 for converting names between Win32 and POSIX, UTF-8-aware, with attendant changes elsewhere
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Tue, 12 Jan 2010 01:38:04 -0600 |
parents | facf3239ba30 |
children | a98ca4640147 |
comparison
equal
deleted
inserted
replaced
4833:4dd2389173fc | 4834:b3ea9c582280 |
---|---|
312 { | 312 { |
313 if (tt_is_err (st)) | 313 if (tt_is_err (st)) |
314 { | 314 { |
315 CIbyte *err; | 315 CIbyte *err; |
316 | 316 |
317 EXTERNAL_TO_C_STRING (tt_status_message (st), err, Qnative); | 317 EXTERNAL_TO_C_STRING (tt_status_message (st), err, Qtooltalk_encoding); |
318 signal_error (Qtooltalk_error, err, Qunbound); | 318 signal_error (Qtooltalk_error, err, Qunbound); |
319 } | 319 } |
320 } | 320 } |
321 | 321 |
322 DEFUN ("receive-tooltalk-message", Freceive_tooltalk_message, 0, 2, 0, /* | 322 DEFUN ("receive-tooltalk-message", Freceive_tooltalk_message, 0, 2, 0, /* |
775 Extbyte *value_ext; | 775 Extbyte *value_ext; |
776 Bytecount value_ext_len; | 776 Bytecount value_ext_len; |
777 CHECK_STRING (value); | 777 CHECK_STRING (value); |
778 TO_EXTERNAL_FORMAT (LISP_STRING, value, | 778 TO_EXTERNAL_FORMAT (LISP_STRING, value, |
779 ALLOCA, (value_ext, value_ext_len), | 779 ALLOCA, (value_ext, value_ext_len), |
780 Qnative); | 780 Qtooltalk_encoding); |
781 tt_message_arg_bval_set (m, n, (unsigned char *) value_ext, value_ext_len); | 781 tt_message_arg_bval_set (m, n, (unsigned char *) value_ext, value_ext_len); |
782 } | 782 } |
783 else if (EQ (attribute, Qtt_arg_ival)) | 783 else if (EQ (attribute, Qtt_arg_ival)) |
784 { | 784 { |
785 CHECK_INT (value); | 785 CHECK_INT (value); |
787 } | 787 } |
788 else if (EQ (attribute, Qtt_arg_val)) | 788 else if (EQ (attribute, Qtt_arg_val)) |
789 { | 789 { |
790 const char *value_ext; | 790 const char *value_ext; |
791 CHECK_STRING (value); | 791 CHECK_STRING (value); |
792 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 792 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
793 tt_message_arg_val_set (m, n, value_ext); | 793 tt_message_arg_val_set (m, n, value_ext); |
794 } | 794 } |
795 else if (EQ (attribute, Qtt_status)) | 795 else if (EQ (attribute, Qtt_status)) |
796 { | 796 { |
797 CHECK_INT (value); | 797 CHECK_INT (value); |
812 | 812 |
813 if (fun_str) | 813 if (fun_str) |
814 { | 814 { |
815 const char *value_ext; | 815 const char *value_ext; |
816 CHECK_STRING (value); | 816 CHECK_STRING (value); |
817 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 817 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
818 (*fun_str) (m, value_ext); | 818 (*fun_str) (m, value_ext); |
819 } | 819 } |
820 | 820 |
821 return Qnil; | 821 return Qnil; |
822 } | 822 } |
928 if (!VALID_TOOLTALK_MESSAGEP (m)) | 928 if (!VALID_TOOLTALK_MESSAGEP (m)) |
929 return Qnil; | 929 return Qnil; |
930 { | 930 { |
931 const char *vtype_ext; | 931 const char *vtype_ext; |
932 | 932 |
933 LISP_STRING_TO_EXTERNAL (vtype, vtype_ext, Qnative); | 933 LISP_STRING_TO_EXTERNAL (vtype, vtype_ext, Qtooltalk_encoding); |
934 if (NILP (value)) | 934 if (NILP (value)) |
935 tt_message_arg_add (m, n, vtype_ext, NULL); | 935 tt_message_arg_add (m, n, vtype_ext, NULL); |
936 else if (STRINGP (value)) | 936 else if (STRINGP (value)) |
937 { | 937 { |
938 const char *value_ext; | 938 const char *value_ext; |
939 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 939 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
940 tt_message_arg_add (m, n, vtype_ext, value_ext); | 940 tt_message_arg_add (m, n, vtype_ext, value_ext); |
941 } | 941 } |
942 else if (INTP (value)) | 942 else if (INTP (value)) |
943 tt_message_iarg_add (m, n, vtype_ext, XINT (value)); | 943 tt_message_iarg_add (m, n, vtype_ext, XINT (value)); |
944 } | 944 } |
1039 } | 1039 } |
1040 else if (EQ (attribute, Qtt_file)) | 1040 else if (EQ (attribute, Qtt_file)) |
1041 { | 1041 { |
1042 const char *value_ext; | 1042 const char *value_ext; |
1043 CHECK_STRING (value); | 1043 CHECK_STRING (value); |
1044 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1044 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1045 tt_pattern_file_add (p, value_ext); | 1045 tt_pattern_file_add (p, value_ext); |
1046 } | 1046 } |
1047 else if (EQ (attribute, Qtt_object)) | 1047 else if (EQ (attribute, Qtt_object)) |
1048 { | 1048 { |
1049 const char *value_ext; | 1049 const char *value_ext; |
1050 CHECK_STRING (value); | 1050 CHECK_STRING (value); |
1051 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1051 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1052 tt_pattern_object_add (p, value_ext); | 1052 tt_pattern_object_add (p, value_ext); |
1053 } | 1053 } |
1054 else if (EQ (attribute, Qtt_op)) | 1054 else if (EQ (attribute, Qtt_op)) |
1055 { | 1055 { |
1056 const char *value_ext; | 1056 const char *value_ext; |
1057 CHECK_STRING (value); | 1057 CHECK_STRING (value); |
1058 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1058 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1059 tt_pattern_op_add (p, value_ext); | 1059 tt_pattern_op_add (p, value_ext); |
1060 } | 1060 } |
1061 else if (EQ (attribute, Qtt_otype)) | 1061 else if (EQ (attribute, Qtt_otype)) |
1062 { | 1062 { |
1063 const char *value_ext; | 1063 const char *value_ext; |
1064 CHECK_STRING (value); | 1064 CHECK_STRING (value); |
1065 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1065 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1066 tt_pattern_otype_add (p, value_ext); | 1066 tt_pattern_otype_add (p, value_ext); |
1067 } | 1067 } |
1068 else if (EQ (attribute, Qtt_scope)) | 1068 else if (EQ (attribute, Qtt_scope)) |
1069 { | 1069 { |
1070 CHECK_TOOLTALK_CONSTANT (value); | 1070 CHECK_TOOLTALK_CONSTANT (value); |
1072 } | 1072 } |
1073 else if (EQ (attribute, Qtt_sender)) | 1073 else if (EQ (attribute, Qtt_sender)) |
1074 { | 1074 { |
1075 const char *value_ext; | 1075 const char *value_ext; |
1076 CHECK_STRING (value); | 1076 CHECK_STRING (value); |
1077 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1077 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1078 tt_pattern_sender_add (p, value_ext); | 1078 tt_pattern_sender_add (p, value_ext); |
1079 } | 1079 } |
1080 else if (EQ (attribute, Qtt_sender_ptype)) | 1080 else if (EQ (attribute, Qtt_sender_ptype)) |
1081 { | 1081 { |
1082 const char *value_ext; | 1082 const char *value_ext; |
1083 CHECK_STRING (value); | 1083 CHECK_STRING (value); |
1084 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1084 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1085 tt_pattern_sender_ptype_add (p, value_ext); | 1085 tt_pattern_sender_ptype_add (p, value_ext); |
1086 } | 1086 } |
1087 else if (EQ (attribute, Qtt_session)) | 1087 else if (EQ (attribute, Qtt_session)) |
1088 { | 1088 { |
1089 const char *value_ext; | 1089 const char *value_ext; |
1090 CHECK_STRING (value); | 1090 CHECK_STRING (value); |
1091 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1091 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1092 tt_pattern_session_add (p, value_ext); | 1092 tt_pattern_session_add (p, value_ext); |
1093 } | 1093 } |
1094 else if (EQ (attribute, Qtt_state)) | 1094 else if (EQ (attribute, Qtt_state)) |
1095 { | 1095 { |
1096 CHECK_TOOLTALK_CONSTANT (value); | 1096 CHECK_TOOLTALK_CONSTANT (value); |
1127 return Qnil; | 1127 return Qnil; |
1128 | 1128 |
1129 { | 1129 { |
1130 const char *vtype_ext; | 1130 const char *vtype_ext; |
1131 | 1131 |
1132 LISP_STRING_TO_EXTERNAL (vtype, vtype_ext, Qnative); | 1132 LISP_STRING_TO_EXTERNAL (vtype, vtype_ext, Qtooltalk_encoding); |
1133 if (NILP (value)) | 1133 if (NILP (value)) |
1134 tt_pattern_arg_add (p, n, vtype_ext, NULL); | 1134 tt_pattern_arg_add (p, n, vtype_ext, NULL); |
1135 else if (STRINGP (value)) | 1135 else if (STRINGP (value)) |
1136 { | 1136 { |
1137 const char *value_ext; | 1137 const char *value_ext; |
1138 LISP_STRING_TO_EXTERNAL (value, value_ext, Qnative); | 1138 LISP_STRING_TO_EXTERNAL (value, value_ext, Qtooltalk_encoding); |
1139 tt_pattern_arg_add (p, n, vtype_ext, value_ext); | 1139 tt_pattern_arg_add (p, n, vtype_ext, value_ext); |
1140 } | 1140 } |
1141 else if (INTP (value)) | 1141 else if (INTP (value)) |
1142 tt_pattern_iarg_add (p, n, vtype_ext, XINT (value)); | 1142 tt_pattern_iarg_add (p, n, vtype_ext, XINT (value)); |
1143 } | 1143 } |