zipruby 0.3.5 → 0.3.6
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of zipruby might be problematic. Click here for more details.
- data/ext/zipruby.h +1 -1
- data/ext/zipruby_archive.c +8 -0
- data/zipruby.c +8 -0
- metadata +1 -1
data/ext/zipruby.h
CHANGED
data/ext/zipruby_archive.c
CHANGED
@@ -359,6 +359,10 @@ static VALUE zipruby_archive_close(VALUE self) {
|
|
359
359
|
rb_raise(Error, "Close archive failed: %s", zip_strerror(p_archive->archive));
|
360
360
|
}
|
361
361
|
|
362
|
+
if (!NIL_P(p_archive->sources)){
|
363
|
+
rb_ary_clear(p_archive->sources);
|
364
|
+
}
|
365
|
+
|
362
366
|
if (!NIL_P(p_archive->buffer) && changed) {
|
363
367
|
rb_funcall(p_archive->buffer, rb_intern("replace"), 1, rb_funcall(self, rb_intern("read"), 0));
|
364
368
|
}
|
@@ -1304,6 +1308,10 @@ static VALUE zipruby_archive_commit(VALUE self) {
|
|
1304
1308
|
rb_raise(Error, "Commit archive failed: %s", zip_strerror(p_archive->archive));
|
1305
1309
|
}
|
1306
1310
|
|
1311
|
+
if (!NIL_P(p_archive->sources)){
|
1312
|
+
rb_ary_clear(p_archive->sources);
|
1313
|
+
}
|
1314
|
+
|
1307
1315
|
if (!NIL_P(p_archive->buffer) && changed) {
|
1308
1316
|
rb_funcall(p_archive->buffer, rb_intern("replace"), 1, rb_funcall(self, rb_intern("read"), 0));
|
1309
1317
|
}
|
data/zipruby.c
CHANGED
@@ -553,6 +553,10 @@ static VALUE zipruby_archive_close(VALUE self) {
|
|
553
553
|
rb_raise(Error, "Close archive failed: %s", zip_strerror(p_archive->archive));
|
554
554
|
}
|
555
555
|
|
556
|
+
if (!NIL_P(p_archive->sources)){
|
557
|
+
rb_ary_clear(p_archive->sources);
|
558
|
+
}
|
559
|
+
|
556
560
|
if (!NIL_P(p_archive->buffer) && changed) {
|
557
561
|
rb_funcall(p_archive->buffer, rb_intern("replace"), 1, rb_funcall(self, rb_intern("read"), 0));
|
558
562
|
}
|
@@ -1498,6 +1502,10 @@ static VALUE zipruby_archive_commit(VALUE self) {
|
|
1498
1502
|
rb_raise(Error, "Commit archive failed: %s", zip_strerror(p_archive->archive));
|
1499
1503
|
}
|
1500
1504
|
|
1505
|
+
if (!NIL_P(p_archive->sources)){
|
1506
|
+
rb_ary_clear(p_archive->sources);
|
1507
|
+
}
|
1508
|
+
|
1501
1509
|
if (!NIL_P(p_archive->buffer) && changed) {
|
1502
1510
|
rb_funcall(p_archive->buffer, rb_intern("replace"), 1, rb_funcall(self, rb_intern("read"), 0));
|
1503
1511
|
}
|