Strange!
You can use
basename to get the last part of a path.
As
sh means sh in Solaris, that's probably the easiest approach.
Edit: Seing that it's backslashes, not forward slashes,
basename might not cut it, but I don't understand if those are normal (ASCII) zero's why
sed would behave this way.
Edit 2: Duh! Because
sed treats \0 as a Null character!
Edit 3: That was a duh @ me, not a duh @ you