mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

160 lines
5.4 KiB

  1. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  2. #
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. # Please add additional copyright information _after_ the line containing
  5. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  6. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  7. #
  8. # ROCK Linux: rock-src/package/rene/sylpheed/gpgme-update.patch
  9. # ROCK Linux is Copyright (C) 1998 - 2004 Clifford Wolf
  10. #
  11. # This patch file is dual-licensed. It is available under the license the
  12. # patched project is licensed under, as long as it is an OpenSource license
  13. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  14. # of the GNU General Public License as published by the Free Software
  15. # Foundation; either version 2 of the License, or (at your option) any later
  16. # version.
  17. #
  18. # --- ROCK-COPYRIGHT-NOTE-END ---
  19. Written by Rene Rebe <rene@exactcode.de> to make sylpheed compile
  20. with recent gpgme, since noone seems to care about this ...
  21. --- sylpheed-0.9.0/src/rfc2015.c.orig 2003-08-03 02:15:15.000000000 +0200
  22. +++ sylpheed-0.9.0/src/rfc2015.c 2003-08-03 02:28:09.000000000 +0200
  23. @@ -340,7 +340,7 @@
  24. goto leave;
  25. }
  26. - err = gpgme_op_verify (ctx, sig, text, &status);
  27. + err = gpgme_op_verify (ctx, sig, text, NULL, &status);
  28. if (err) {
  29. debug_print ("gpgme_op_verify failed: %s\n", gpgme_strerror (err));
  30. goto leave;
  31. @@ -395,11 +395,11 @@
  32. if (err)
  33. debug_print ("gpgme_data_rewind failed: %s\n", gpgme_strerror (err));
  34. - while (!(err = gpgme_data_read (data, buf, 100, &nread))) {
  35. + while ((nread = gpgme_data_read (data, buf, 100)) > 0) {
  36. fwrite ( buf, nread, 1, fp );
  37. }
  38. - if (err != GPGME_EOF)
  39. + if (nread != GPGME_EOF)
  40. debug_print ("gpgme_data_read failed: %s\n", gpgme_strerror (err));
  41. fclose (fp);
  42. @@ -666,11 +666,11 @@
  43. if (err)
  44. debug_print ("gpgme_data_rewind failed: %s\n", gpgme_strerror (err));
  45. - while (!(err = gpgme_data_read (plain, buf, sizeof(buf), &nread))) {
  46. + while ((nread = gpgme_data_read (plain, buf, sizeof(buf))) > 0) {
  47. fwrite (buf, nread, 1, dstfp);
  48. }
  49. - if (err != GPGME_EOF) {
  50. + if (nread != GPGME_EOF) {
  51. debug_print ("gpgme_data_read failed: %s\n", gpgme_strerror (err));
  52. }
  53. @@ -885,10 +885,10 @@
  54. debug_print ("gpgme_data_rewind failed: %s\n", gpgme_strerror (err));
  55. goto failure;
  56. }
  57. - while (!(err = gpgme_data_read (header, buf, BUFFSIZE, &nread))) {
  58. + while ((nread = gpgme_data_read (header, buf, BUFFSIZE)) > 0) {
  59. fwrite (buf, nread, 1, fp);
  60. }
  61. - if (err != GPGME_EOF) {
  62. + if (nread != GPGME_EOF) {
  63. debug_print ("gpgme_data_read failed: %s\n", gpgme_strerror (err));
  64. goto failure;
  65. }
  66. @@ -931,10 +931,10 @@
  67. goto failure;
  68. }
  69. - while (!(err = gpgme_data_read (cipher, buf, BUFFSIZE, &nread))) {
  70. + while ((nread = gpgme_data_read (cipher, buf, BUFFSIZE)) > 0) {
  71. fwrite (buf, nread, 1, fp);
  72. }
  73. - if (err != GPGME_EOF) {
  74. + if (nread != GPGME_EOF) {
  75. debug_print ("** gpgme_data_read failed: %s\n", gpgme_strerror (err));
  76. goto failure;
  77. }
  78. @@ -1204,10 +1204,10 @@
  79. err = gpgme_data_rewind (header);
  80. if (err)
  81. debug_print ("gpgme_data_rewind failed: %s\n", gpgme_strerror (err));
  82. - while (!(err = gpgme_data_read (header, buf, BUFFSIZE, &nread))) {
  83. + while ((nread = gpgme_data_read (header, buf, BUFFSIZE)) > 0) {
  84. fwrite (buf, nread, 1, fp);
  85. }
  86. - if (err != GPGME_EOF) {
  87. + if (nread != GPGME_EOF) {
  88. debug_print ("gpgme_data_read failed: %s\n", gpgme_strerror (err));
  89. goto failure;
  90. }
  91. @@ -1236,10 +1236,10 @@
  92. gpgme_strerror (err));
  93. goto failure;
  94. }
  95. - while (!(err = gpgme_data_read (plain, buf, BUFFSIZE, &nread))) {
  96. + while ((nread = gpgme_data_read (plain, buf, BUFFSIZE)) > 0) {
  97. fwrite (buf, nread, 1, fp);
  98. }
  99. - if (err != GPGME_EOF) {
  100. + if (nread != GPGME_EOF) {
  101. debug_print ("gpgme_data_read failed: %s\n", gpgme_strerror (err));
  102. goto failure;
  103. }
  104. @@ -1258,10 +1258,10 @@
  105. goto failure;
  106. }
  107. - while (!(err = gpgme_data_read (sigdata, buf, BUFFSIZE, &nread))) {
  108. + while ((nread = gpgme_data_read (sigdata, buf, BUFFSIZE)) > 0) {
  109. fwrite (buf, nread, 1, fp);
  110. }
  111. - if (err != GPGME_EOF) {
  112. + if (nread != GPGME_EOF) {
  113. debug_print ("gpgme_data_read failed: %s\n", gpgme_strerror (err));
  114. goto failure;
  115. }
  116. @@ -1356,10 +1356,10 @@
  117. goto failure;
  118. }
  119. - while (!(err = gpgme_data_read(sigdata, buf, sizeof(buf), &nread))) {
  120. + while ((nread = gpgme_data_read(sigdata, buf, sizeof(buf))) > 0) {
  121. fwrite(buf, nread, 1, fp);
  122. }
  123. - if (err != GPGME_EOF) {
  124. + if (nread != GPGME_EOF) {
  125. debug_print("gpgme_data_read failed: %s\n", gpgme_strerror(err));
  126. goto failure;
  127. }
  128. --- sylpheed-0.9.0/src/main.c.orig 2003-08-03 02:40:06.000000000 +0200
  129. +++ sylpheed-0.9.0/src/main.c 2003-08-03 02:34:24.000000000 +0200
  130. @@ -231,7 +231,7 @@
  131. prefs_common_read_config();
  132. #if USE_GPGME
  133. - if (gpgme_check_engine()) { /* Also does some gpgme init */
  134. + /*if (gpgme_check_engine()) { */ /* Also does some gpgme init */
  135. rfc2015_disable_all();
  136. debug_print("gpgme_engine_version:\n%s\n",
  137. gpgme_get_engine_info());
  138. @@ -246,7 +246,7 @@
  139. if (val & G_ALERTDISABLE)
  140. prefs_common.gpg_warning = FALSE;
  141. }
  142. - }
  143. + /* } */
  144. gpgme_register_idle(idle_function_for_gpgme);
  145. #endif