Jump to content

Buffer reuse gone wrong


PJM_labview

Recommended Posts

This bug is a little tricky to explain.

First download the attached VI.

Download File:post-121-1222274788.vi

post-121-1222277071.png?width=400

Now Open its BD and from there open the FP of "Get Image Subset.vi" and put each FP side by side.

Step 1

Run the VI with the "White is transparent" flag set to FALSE.

Here is the result:

post-121-1222275251.png?width=400

So far so Good (note: I highlight the structure where problem will show next)

Step 2

Run the VI with the "White is transparent" flag set to TRUE.

Here is the result:

post-121-1222275460.png?width=400

Somehow the buffer of the cluster is being reused and some data that should not be there are present.

Note: at that stage there are no visible effect of this bug on the "Get Tree Symbols (LV86).vi".

Step 3

Run the VI with the "White is transparent" flag set to FALSE.

Here is the result:

post-121-1222275951.png?width=400

Now we can see the effect of the bug on the "Get Tree Symbols (LV86).vi".

From that point on there are no non edit way to have this vi work properly. Setting the "White is transparent" flag to false always return an array of blank image symbols.

Disconnecting the image data wire (at any place) and reconnecting it does temporary fix the bug until going back to the 3 steps. forcing LV to not reuse the buffer by creating another wire branch (see image below) is the only workaround that I have found.

post-121-1222276464.png?width=400

PJM

PS: This bug is also present in LV 8.5 (I have not tried earlier version)

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.