LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

is RegExpr FP thread safe?

Are the regular expression functions in the regexpr.fp thread safe?

Menchar
0 Kudos
Message 1 of 5
(3,711 Views)
Hi Menchar,

Those functions are not thread safe; the header file (regexpr.h) includes a warning at the top of the file that mentions this. Hope this answers your question.

Regards,
Ebele O.
National Instruments
0 Kudos
Message 2 of 5
(3,686 Views)
Ebele -

Thanks for the info.

It would be really cool if the CVI regular expression code were thread safe and could parse across a newline character. 

Menchar




0 Kudos
Message 3 of 5
(3,678 Views)
Actually, if you have CVI 8.0 or higher then this code is thread-safe. The comments are obsolete and should (will) be removed in the next release. You can verify if the code was made thread safe by looking at regexpr.c - you should see calls to GetLock, etc.
0 Kudos
Message 4 of 5
(3,664 Views)
Thanks - I do see where it looks like it's set up to be threadsafe but when the comments say it's not (and the NI person says, "well, duh - read the comments") it makes one hesitate Smiley Wink  I thought maybe it was a work in progress or that it hadn't been checked out.  That's why I asked.

Now if they could get it to parse across a newline character  ...

Menchar



0 Kudos
Message 5 of 5
(3,654 Views)