Cannot find drvector_clear

7 views
Skip to first unread message

Ao Vak

unread,
May 30, 2026, 12:10:25 AM (4 days ago) May 30
to DynamoRIO Users
Hello hello

I am using drvector to store a dynamic list (as expected) and need to regularly clear all the elements of the vector throughout the lifespan of the client
I found the drvector_clear method in the docs, and it seems like it would be ideal for this, but it is nowhere to be found in drvector.h. I am using the latest version of DynamoRIO

Why don't I have access to it?
Right now I'm doing drvector_delete followed by drvector_init to clear a vector, which doesn't seem ideal.

Also I don't know if this is a bug, but doing drvector_init, drvector_delete, then drvector_append doesn't cause issues and appends to the vector fine, but doing drvector_delete again and then drvector_append makes drvector_append crash the client, which is strange.....

Derek Bruening

unread,
May 30, 2026, 11:07:25 AM (3 days ago) May 30
to Ao Vak, DynamoRIO Users
On Sat, May 30, 2026 at 12:10 AM Ao Vak <aova...@gmail.com> wrote:
Hello hello

I am using drvector to store a dynamic list (as expected) and need to regularly clear all the elements of the vector throughout the lifespan of the client
I found the drvector_clear method in the docs, and it seems like it would be ideal for this, but it is nowhere to be found in drvector.h. I am using the latest version of DynamoRIO

Why don't I have access to it?
Right now I'm doing drvector_delete followed by drvector_init to clear a vector, which doesn't seem ideal.

The online docs match the weekly cronbuilds at https://github.com/DynamoRIO/dynamorio/releases. If you are using the last "official" release 11.3 you would want to look at the docs inside the 11.3 package itself. drvector_clear was added after the 11.3 release.  I would suggest using the latest weekly cronbuild and then you will have access to drvector_clear.
  

Also I don't know if this is a bug, but doing drvector_init, drvector_delete, then drvector_append doesn't cause issues and appends to the vector fine, but doing drvector_delete again and then drvector_append makes drvector_append crash the client, which is strange.....

You mean there was no drvector_init call after the 2nd drvector_delete? Wouldn't that explain the failure? 

--
You received this message because you are subscribed to the Google Groups "DynamoRIO Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dynamorio-use...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dynamorio-users/9d8e8b47-3af0-404c-b0d3-ac542955d02an%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages