Finding one string located in another
Here are my comments:

Functionality:


Remove the superfluous start parameter.
Remove all needlessly complex (and slow) pointer arithmetic.
Use the standard wcslen() function from wchar.h
Position 0 is a valid array index, replace it with an invalid one if value not found.


Performance:


Only call the strlen function once.
Minimize the code inside the if/else statement.


Readability and style:


str isn't modified by the function, so make it const (const correctness).
Rewrite the loop to a conventional one.
Only return once from a function.
Replace all "magic numbers" with constants or enums.


-

#include &lt;stddef.h&gt;
#include &lt;wchar.h&gt;
#include &lt;stdio.h&gt;

typedef enum
{
  DIR_POS,
  DIR_NEG 
} dir_t;


#define NOT_FOUND -1


int myInstr (const wchar_t*  str,
             wchar_t         c,
             dir_t           dir)
{
  int start;
  int end;
  int step;
  int length;
  int i;
  int result = NOT_FOUND;

  length = wcslen(str);

  if(dir == DIR_POS)
  {
    start = 0;
    end   = length;
    step  = 1;
  }
  else /* if (dir == DIR_NEG) */
  {
    start = length - 1;
    end   = -1;
    step  = -1;
  }

  for(i=start; i!=end; i+=step)
  {
    if(str[i] == c)
    {
      result = i;
      break;
    }
  }

  return result;
}


int main()
{
  wchar_t str [] = L"1234567890";

  printf("%d\n", myInstr(str, '3', DIR_POS)); // prints 2
  printf("%d\n", myInstr(str, '6', DIR_NEG)); // prints 5
  printf("%d\n", myInstr(str, 'X', DIR_POS)); // prints -1
}