jevey / idapython

Automatically exported from code.google.com/p/idapython
Other
1 stars 0 forks source link

Call to GetStringType is failing #45

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
here's the code from idc.py:
> def GetStringType(ea):
>     """
>     Get string type
>
>     @param ea: linear address
>
>     @return: One of ASCSTR_... constants
>     """
>     ti = idaapi.typeinfo_t()     <<<--------------------  should we wrap
in try, except to return none?
>
>     if idaapi.get_typeinfo(ea, 0, GetFlags(ea), ti):
>         return ti.strtype
>     else:
>         return None
>
>
>
> here is the code from instruction.py:
>   if opnum:
>             op0 = idaapi.get_instruction_operand(instruction, opnum)
>
>             if op0.value and op0.type == o_imm and GetStringType(self.ea) ==
> None:   <<---- we're looking for none
>                 return op0.value
>

Original issue reported on code.google.com by demott...@gmail.com on 26 Jan 2010 at 7:20

GoogleCodeExporter commented 9 years ago
File "C:\Program Files\IDA\python\idc.py", line 2298, in GetStringType
    ti = idaapi.typeinfo_t()
AttributeError: 'module' object has no attribute 'typeinfo_t'

That's the actual crash error.

Original comment by demott...@gmail.com on 26 Jan 2010 at 8:18

GoogleCodeExporter commented 9 years ago
Fixed please verify

Original comment by elias.ba...@gmail.com on 27 Jan 2010 at 9:54