We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello
Lets assume that we have this example PHP code, lets run it ;)
$ cat test_mail.php <?php $to = 'nobody@example.com'; $subject = 'Test'; $message = 'Test message.'; $headers = 'From: webmaster@example.com' . "\r\n" . 'Reply-To: webmaster@example.com' . "\r\n" . 'X-Mailer: PHP/' . phpversion(); $result = mail($to, $subject, $message, $headers); var_dump($result);
Here is the result
$ php test_mail.php panic: runtime error: slice bounds out of range goroutine 1 [running]: github.com/mailhog/mhsendmail/cmd.Go() /home/vagrant/go/src/github.com/mailhog/mhsendmail/cmd/cmd.go:72 +0x10ce main.main() /home/vagrant/go/src/github.com/mailhog/mhsendmail/main.go:6 +0x14 goroutine 17 [syscall, locked to thread]: runtime.goexit() /usr/lib/go/src/runtime/asm_amd64.s:1696 +0x1
Here is the config
$ cat /etc/php5/cli/conf.d/zz-hitmeister.ini | grep sendmail_path sendmail_path = /usr/bin/env /home/vagrant/go/bin/mhsendmail
Looks like it is almost the same as #3 . Hope you will have time to fix it ;)
have a nice day
The text was updated successfully, but these errors were encountered:
diff --git a/cmd/cmd.go b/cmd/cmd.go index b8860ef..251dcfd 100644 --- a/cmd/cmd.go +++ b/cmd/cmd.go @@ -69,6 +69,12 @@ func Go() { // provided on the command line. re := regexp.MustCompile("(?im)^To: (.*)\r\n$") n := bytes.IndexByte(body, 0)
var bodyStr string;
if n < 0 {
bodyStr = string(body)
} else {
bodyStr = string(body[:n])
} bodyStr := string(body[:n]) includedRecip := re.FindAllString(bodyStr, -1) if includedRecip == nil {
Sorry, something went wrong.
Fixed runtime error: slice bounds out of range
98ecd08
mailhog#5
think this has been fixed by 664083f
No branches or pull requests
Hello
Lets assume that we have this example PHP code, lets run it ;)
Here is the result
Here is the config
Looks like it is almost the same as #3 . Hope you will have time to fix it ;)
have a nice day
The text was updated successfully, but these errors were encountered: