Documentation error:


#1

Surely, that should say, “if it is present in the src buffer” :question:

Reference: WM_DEV_OAT_UGD_080
Revision: 007
Date: February 2009


#2

Also it is same in Basic Development Guide for Open AT OS v3.13.

Looks like it is just copy pasted from older version without verify during documentation.

Also please look wm_strSwitch() functionality.


#3

Yes, I think so!

The documentation also does not say what happens to the dst string when the specified parameter is not present in the src string:

What actually happens is that the dst string is set to the empty string;
ie, dst[0] = 0.


#4

See: viewtopic.php?f=3&t=4234&p=16935&hilit=wm_strSwitch#p16811 :question:


#5

The definition of when a parameter is “present” is also not clearly explained:

Clearly contains 3 parameters, so parameters 1-3 are “present”, parameters 4+ are “not present”.

But what about:

In fact, again, this is considered to contain three parameters:

  • Parameter number 1 is present, and has the value “P1”;

  • Parameter number 2 is present, and has a null value;

  • Parameter number 3 is present, and has the value “P3”;

  • Parameters numbered 4 & above are not present.