stropheruby 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/History.txt +4 -0
  2. data/ext/strophe_ruby.c +15 -15
  3. metadata +3 -19
@@ -1,3 +1,7 @@
1
+ == 0.2.2 2011-06-09
2
+
3
+ * STR2CSTR is deprecated and use StringValuePtr instead
4
+
1
5
  == 0.2.1 2010-09-19
2
6
 
3
7
  * Scope md5 function to avoid name clashing
@@ -162,7 +162,7 @@ static VALUE t_xmpp_conn_get_jid(VALUE self) {
162
162
  static VALUE t_xmpp_conn_set_jid(VALUE self, VALUE jid) {
163
163
  xmpp_conn_t *conn;
164
164
  Data_Get_Struct(self, xmpp_conn_t, conn);
165
- xmpp_conn_set_jid(conn, STR2CSTR(jid));
165
+ xmpp_conn_set_jid(conn, StringValuePtr(jid));
166
166
  return jid;
167
167
  }
168
168
 
@@ -177,7 +177,7 @@ static VALUE t_xmpp_conn_get_pass(VALUE self) {
177
177
  static VALUE t_xmpp_conn_set_pass(VALUE self, VALUE pass) {
178
178
  xmpp_conn_t *conn;
179
179
  Data_Get_Struct(self, xmpp_conn_t, conn);
180
- xmpp_conn_set_pass(conn, STR2CSTR(pass));
180
+ xmpp_conn_set_pass(conn, StringValuePtr(pass));
181
181
  return pass;
182
182
  }
183
183
 
@@ -301,7 +301,7 @@ int _id_handler(xmpp_conn_t * const conn,
301
301
  static VALUE t_xmpp_handler_add(VALUE self,VALUE rb_name) {
302
302
  xmpp_conn_t *conn;
303
303
  Data_Get_Struct(self, xmpp_conn_t, conn);
304
- char *name = STR2CSTR(rb_name);
304
+ char *name = StringValuePtr(rb_name);
305
305
  VALUE arr;
306
306
  xmpp_handler handler;
307
307
 
@@ -327,12 +327,12 @@ static VALUE t_xmpp_handler_add(VALUE self,VALUE rb_name) {
327
327
  static VALUE t_xmpp_id_handler_add(VALUE self, VALUE rb_id) {
328
328
  xmpp_conn_t *conn;
329
329
  Data_Get_Struct(self, xmpp_conn_t, conn);
330
- char *id = STR2CSTR(rb_id);
330
+ char *id = StringValuePtr(rb_id);
331
331
  VALUE arr;
332
332
 
333
333
  arr = rb_iv_get(self, "@id_handlers");
334
334
  rb_ary_push(arr, rb_block_proc());
335
- xmpp_id_handler_add(conn, _id_handler, STR2CSTR(id), conn->ctx);
335
+ xmpp_id_handler_add(conn, _id_handler, StringValuePtr(id), conn->ctx);
336
336
  return Qnil;
337
337
  }
338
338
 
@@ -381,7 +381,7 @@ static VALUE t_xmpp_send_raw_string(VALUE self, VALUE rb_text) {
381
381
  char *text;
382
382
 
383
383
  Data_Get_Struct(self, xmpp_conn_t, conn);
384
- text = STR2CSTR(rb_text);
384
+ text = StringValuePtr(rb_text);
385
385
 
386
386
  xmpp_send_raw_string(conn, "%s", text);
387
387
  return Qtrue;
@@ -441,7 +441,7 @@ static VALUE t_xmpp_stanza_get_child_by_name(VALUE self, VALUE rb_name) {
441
441
  xmpp_stanza_t *child;
442
442
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
443
443
 
444
- char *name = STR2CSTR(rb_name);
444
+ char *name = StringValuePtr(rb_name);
445
445
  child = xmpp_stanza_get_child_by_name(stanza, name);
446
446
 
447
447
  if(child) {
@@ -469,7 +469,7 @@ static VALUE t_xmpp_stanza_get_attribute(VALUE self, VALUE rb_attribute) {
469
469
  xmpp_stanza_t *stanza;
470
470
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
471
471
 
472
- char *val = xmpp_stanza_get_attribute(stanza,STR2CSTR(rb_attribute));
472
+ char *val = xmpp_stanza_get_attribute(stanza,StringValuePtr(rb_attribute));
473
473
  return rb_str_new2(val);
474
474
  }
475
475
 
@@ -531,8 +531,8 @@ static VALUE t_xmpp_stanza_set_attribute(VALUE self, VALUE rb_attribute, VALUE r
531
531
  xmpp_stanza_t *stanza;
532
532
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
533
533
 
534
- char *attribute = STR2CSTR(rb_attribute);
535
- char *val = STR2CSTR(rb_val);
534
+ char *attribute = StringValuePtr(rb_attribute);
535
+ char *val = StringValuePtr(rb_val);
536
536
 
537
537
  xmpp_stanza_set_attribute(stanza, attribute, val);
538
538
  return Qtrue;
@@ -543,7 +543,7 @@ static VALUE t_xmpp_stanza_set_ns(VALUE self, VALUE rb_ns) {
543
543
  xmpp_stanza_t *stanza;
544
544
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
545
545
 
546
- char *ns = STR2CSTR(rb_ns);
546
+ char *ns = StringValuePtr(rb_ns);
547
547
 
548
548
  xmpp_stanza_set_ns(stanza, ns);
549
549
  return Qtrue;
@@ -568,7 +568,7 @@ static VALUE t_xmpp_stanza_set_text(VALUE self, VALUE rb_text) {
568
568
  xmpp_stanza_t *stanza;
569
569
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
570
570
 
571
- char *text = STR2CSTR(rb_text);
571
+ char *text = StringValuePtr(rb_text);
572
572
 
573
573
  xmpp_stanza_set_text(stanza, text);
574
574
  return rb_text;
@@ -579,7 +579,7 @@ static VALUE t_xmpp_stanza_set_name(VALUE self, VALUE rb_name) {
579
579
  xmpp_stanza_t *stanza;
580
580
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
581
581
 
582
- char *name = STR2CSTR(rb_name);
582
+ char *name = StringValuePtr(rb_name);
583
583
 
584
584
  xmpp_stanza_set_name(stanza, name);
585
585
  return Qtrue;
@@ -590,7 +590,7 @@ static VALUE t_xmpp_stanza_set_type(VALUE self, VALUE rb_type) {
590
590
  xmpp_stanza_t *stanza;
591
591
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
592
592
 
593
- char *type = STR2CSTR(rb_type);
593
+ char *type = StringValuePtr(rb_type);
594
594
 
595
595
  xmpp_stanza_set_type(stanza, type);
596
596
  return Qtrue;
@@ -601,7 +601,7 @@ static VALUE t_xmpp_stanza_set_id(VALUE self, VALUE rb_id) {
601
601
  xmpp_stanza_t *stanza;
602
602
  Data_Get_Struct(self, xmpp_stanza_t, stanza);
603
603
 
604
- char *id = STR2CSTR(rb_id);
604
+ char *id = StringValuePtr(rb_id);
605
605
 
606
606
  xmpp_stanza_set_id(stanza, id);
607
607
  return Qtrue;
metadata CHANGED
@@ -1,13 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stropheruby
3
3
  version: !ruby/object:Gem::Version
4
- hash: 21
5
- prerelease: false
6
- segments:
7
- - 0
8
- - 2
9
- - 1
10
- version: 0.2.1
4
+ prerelease:
5
+ version: 0.2.2
11
6
  platform: ruby
12
7
  authors:
13
8
  - "Fran\xC3\xA7ois Lamontagne"
@@ -28,11 +23,6 @@ dependencies:
28
23
  requirements:
29
24
  - - ">="
30
25
  - !ruby/object:Gem::Version
31
- hash: 49
32
- segments:
33
- - 1
34
- - 8
35
- - 3
36
26
  version: 1.8.3
37
27
  type: :development
38
28
  version_requirements: *id001
@@ -107,23 +97,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
107
97
  requirements:
108
98
  - - ">="
109
99
  - !ruby/object:Gem::Version
110
- hash: 3
111
- segments:
112
- - 0
113
100
  version: "0"
114
101
  required_rubygems_version: !ruby/object:Gem::Requirement
115
102
  none: false
116
103
  requirements:
117
104
  - - ">="
118
105
  - !ruby/object:Gem::Version
119
- hash: 3
120
- segments:
121
- - 0
122
106
  version: "0"
123
107
  requirements: []
124
108
 
125
109
  rubyforge_project: strophe_ruby
126
- rubygems_version: 1.3.7
110
+ rubygems_version: 1.6.1
127
111
  signing_key:
128
112
  specification_version: 2
129
113
  summary: strophe_ruby