tag 765074 + patch thanks Hi,
The problem is that vagrant inserts a newline after the User-Agent header: HEAD /wheezy64.box HTTP/1.1 User-Agent: Vagrant/1.6.5 Host: vagrant.1024.lu Accept: application/json HTTP/1.1 400 Bad Request Date: Tue, 28 Oct 2014 08:03:46 GMT Server: Apache Vary: Accept-Encoding Connection: close Content-Type: text/html; charset=iso-8859-1 It comes from the VERSION string which contains a newline. Adding a ".chomp" call (see attached patch) resolves the issue. Note that this actually breaks every HTTP request so it makes vagrant barely useable. It works only if you downloaded an image with a previous version, or with file:// urls, so the severity should be raised IMHO. Cheers and thanks for taking care of Vagrant! -- Etienne Millon
From c318c4152404ac4beaa78d14d55cd7e31dcaaae9 Mon Sep 17 00:00:00 2001 From: Etienne Millon <m...@emillon.org> Date: Tue, 28 Oct 2014 09:12:51 +0100 Subject: [PATCH] Chomp newline after version number --- debian/changelog | 7 +++++++ .../0003-VERSION-fallback-to-usr-share-vagrant-version.txt.patch | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 85e5904..8ffcc98 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +vagrant (1.6.5+dfsg1-1.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Chomp newline after version number (Closes: #765074) + + -- Etienne Millon <m...@emillon.org> Tue, 28 Oct 2014 09:11:45 +0100 + vagrant (1.6.5+dfsg1-1) unstable; urgency=medium [ Antonio Terceiro ] diff --git a/debian/patches/0003-VERSION-fallback-to-usr-share-vagrant-version.txt.patch b/debian/patches/0003-VERSION-fallback-to-usr-share-vagrant-version.txt.patch index 9c2cd03..775f20f 100644 --- a/debian/patches/0003-VERSION-fallback-to-usr-share-vagrant-version.txt.patch +++ b/debian/patches/0003-VERSION-fallback-to-usr-share-vagrant-version.txt.patch @@ -21,7 +21,7 @@ index 0640365..22f6188 100644 + VERSION = File.read( + File.expand_path("../../../version.txt", __FILE__)).chomp + rescue Errno::ENOENT -+ VERSION = File.read('/usr/share/vagrant/version.txt') ++ VERSION = File.read('/usr/share/vagrant/version.txt').chomp + end end -- -- 2.1.1
signature.asc
Description: Digital signature