<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Hari Sekhon wrote:
<blockquote cite="mid44E03F59.2070607@googlemail.com" type="cite">
  <pre wrap="">Thomas Sluyter wrote:
  </pre>
  <blockquote type="cite">
    <blockquote type="cite">
      <pre wrap="">After following your suggestion regarding prinf and checking the 
previously unchanged misccommand.cfg I'm not entirely sure what is 
going on here. The definition for email is below:
...
This doesn't look bad to me, it seems to simply be using lots of 
Macro$ so I assume that the macro must be sending it something funny....
Will have to scratch my head and try to track that down.
      </pre>
    </blockquote>
    <pre wrap="">You -did- notice that to printf "\b" is a backspace, right? Which 
would totally explain what you're seeing...

    </pre>
  </blockquote>
  <pre wrap=""><!---->err, I think that is the notation for a backslash escaped sequence, not 
a backspace character, which is \b.

It turns out that the points at which I am getting those strange squares 
is actually replacing "\\" and "\" in \\hostname\sharename.

So I know where the problem is and what part needs fixing, but I have 
tried to recreate it on the command line but the message never comes 
through to me to fully diagnose.

eg..

echo '\\hostname\sharename' | mail -s "test" <a class="moz-txt-link-abbreviated" href="mailto:me@mydomain.com">me@mydomain.com</a>

but I haven't gotten this. Strange, that now I'm not getting messages 
from /bin/mail. Will have to look into this and get back to you.


Hari

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
<a class="moz-txt-link-freetext" href="http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642">http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642</a>
_______________________________________________
Nagios-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a>
<a class="moz-txt-link-freetext" href="https://lists.sourceforge.net/lists/listinfo/nagios-users">https://lists.sourceforge.net/lists/listinfo/nagios-users</a>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null

  </pre>
</blockquote>
<br>
ok, after looking at my mail server the problem was the oh so brilliant
thunderbird client. sorted. now back to the original problem...<br>
<br>
<br>
I've fixed the character issue in the notifications with
\\hostname\sharename. The problem lies with the %b in the printf
statement. I changed this to %q. Remember that the system's printf is
superseded by the shell  built-in. Any way, the %q defines that the
argument list is appropriately formatted for shell reuse which is
exactly the was that it is being used in the mail pipe for this
notification functionality.<br>
<br>
Thanks for the help, you've given me the jolt I needed.<br>
<br>
Hari<br>
<br>
<br>
</body>
</html>