Skip to content

embOS IsRunning variable must be cleaned #51

@GAllevato

Description

@GAllevato

Dear maintainers,

it seems like some embOS versions have additional characters in their isRunning variable, e.g.

isRunning = "1 \001"

instead of

isRunning = "1".

Therefore, the check in

rtos-views/src/rtos/rtos-embos.ts

Line 192: if (undefined !== isRunning && !isNaN(isRunning) && 0 !== parseInt(isRunning)) {

fails.

I suggest cleaning the variable in Line 186:

if (Object.hasOwn(this.OSGlobalVal, 'IsRunning')) {
isRunning = this.OSGlobalVal['IsRunning']?.val;
isRunning = isRunning.replace(/'\[0-9]+'/, '').trim();
} else {
....

Kind regards

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions