Bug #4012
closedGet segmentation fault when trying to call method from 3rd party's API
Description
=begin
I tried to call a method in an interface from 3rd party's API. The interface has been successfully found by ole_query_interface, while at next step of calling the method inside, I got a segmentation fault. And I think the parameters I passed into the method are correct.
This implementation is using HP Quality Center Open Test Architecture API.
Interface: ISupportCopyPaste
Public Method: CopyToClipBoard
Syntax (Visual Basic):
Public Function CopyToClipBoard( _
ByVal IDSFilter As String, _
Optional ByVal mode As Long = 0, _
Optional ByVal Path As String = "" _
) As String
Parameters:
IDSFilter
Either comma separated list of ID numbers or a TDFilter.Text that qualifies the items to be copied.
mode
Unused
Path
Use when copying a folder. The path of the folder.
Return Type:
The data copied to the clipboard.
Codes Snippet:
iscp = tstsf.ole_query_interface(iid_ISupportCopyPaste)
clipboard = iscp.CopyToClipBoard(copied_id)
# or replace above one with below
# clipboard = iscp.CopyToClipBoard(copied_id, 0, "")
Error info:
-- control frame ----------
c:0004 p:---- s:0025 b:0025 l:000024 d:000024 CFUNC :method_missing
c:0003 p:0612 s:0023 b:0023 l:00118c d:001980 EVAL qc.rb:76
c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH
c:0001 p:0000 s:0002 b:0002 l:00118c d:00118c TOP
-- Ruby level backtrace information ----------------------------------------
qc.rb:76:in <main>' qc.rb:76:in
method_missing'
=end
Files