Bug #3636

win32ole, is U_UI2REF or V_UI2REF?

Added by Luis Lavena over 4 years ago. Updated almost 4 years ago.

[ruby-core:31564]
Status:Closed
Priority:Normal
Assignee:-
ruby -v:ruby 1.8.7 (2010-06-23 patchlevel 299) [i386-mingw32] Backport:

Description

=begin
Hello,

Looking into a cross-compilation bug, found the following define in ext/win32ole/win32ole.c, line 67:

#ifndef U_UI2REF
#define V_UI2REF(X) V_UNION(X, puiVal)
#endif

Looks like a typo, as I receive the following message using mingw-w64 targetting w32:

/Users/luis/projects/oss/ruby/ext/win32ole/win32ole.c:67:0: warning: "V_UI2REF" redefined [enabled by default]
/Users/luis/mingw/w32/bin/../lib/gcc/i686-w64-mingw32/4.6.0/../../../../i686-w64-mingw32/include/oleauto.h:685:0: note: this is the location of the previous definition

The following change resolves the warning:

diff --git a/ext/win32ole/win32ole.c b/ext/win32ole/win32ole.c
index 98a9380..3f0889f 100644
--- a/ext/win32ole/win32ole.c
+++ b/ext/win32ole/win32ole.c
@@ -64,7 +64,7 @@
#define V_I1REF(X) V_UNION(X, pcVal)
#endif

-#ifndef U_UI2REF
+#ifndef V_UI2REF
#define V_UI2REF(X) V_UNION(X, puiVal)
#endif

Thank you.
=end

Associated revisions

Revision 28809
Added by Masaki Suketa over 4 years ago

  • ext/win32ole/win32ole.c: fix typo. [Bug #3636]

Revision 28809
Added by Masaki Suketa over 4 years ago

  • ext/win32ole/win32ole.c: fix typo. [Bug #3636]

History

#1 Updated by Masaki Suketa over 4 years ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

=begin
This issue was solved with changeset r28809.
Luis, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.

=end

#2 Updated by Luis Lavena over 4 years ago

=begin
Can this be backported to ruby_1_9_2 too? Thank you.
=end

Also available in: Atom PDF