bump version to 3.1-44, re-add spiceconfig support
This commit is contained in:
parent
1d4b0dfb89
commit
76cef29b27
@ -48,7 +48,7 @@ my $baseuri = "/api2";
|
||||
sub split_abs_uri {
|
||||
my ($abs_uri) = @_;
|
||||
|
||||
my ($format, $rel_uri) = $abs_uri =~ m/^\Q$baseuri\E\/+(html|text|json|extjs|png|htmljs)(\/.*)?$/;
|
||||
my ($format, $rel_uri) = $abs_uri =~ m/^\Q$baseuri\E\/+(html|text|json|extjs|png|htmljs|spiceconfig)(\/.*)?$/;
|
||||
$rel_uri = '/' if !$rel_uri;
|
||||
|
||||
return wantarray ? ($rel_uri, $format) : $rel_uri;
|
||||
|
@ -111,6 +111,14 @@ sub format_response_data {
|
||||
# we use this for extjs file upload forms
|
||||
$ct = 'text/html;charset=UTF-8';
|
||||
$raw = encode_entities(to_json($data, {allow_nonref => 1}));
|
||||
} elsif ($format eq 'spiceconfig') {
|
||||
$ct = 'application/x-virt-viewer;charset=UTF-8';
|
||||
if ($data && ref($data) && ref($data->{data})) {
|
||||
$raw = "[virt-viewer]\n";
|
||||
while (my ($key, $value) = each %{$data->{data}}) {
|
||||
$raw .= "$key=$value\n" if defined($value);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$ct = 'text/plain;charset=UTF-8';
|
||||
$raw = to_json($data, {utf8 => 1, allow_nonref => 1, pretty => 1});
|
||||
|
8
debian/changelog.Debian
vendored
8
debian/changelog.Debian
vendored
@ -1,3 +1,11 @@
|
||||
pve-manager (3.1-44) unstable; urgency=low
|
||||
|
||||
* re-add support for spiceconfig output format (revert commit
|
||||
97da4646288d2806c334c6a1c1361acb22df0535 and commit
|
||||
b96fb2234a7df02999489cc1f33ad52defac8998)
|
||||
|
||||
-- Proxmox Support Team <support@proxmox.com> Mon, 24 Feb 2014 12:49:35 +0100
|
||||
|
||||
pve-manager (3.1-43) unstable; urgency=low
|
||||
|
||||
* fix network API (make comments optional)
|
||||
|
@ -2,7 +2,7 @@ RELEASE=3.1
|
||||
|
||||
VERSION=3.1
|
||||
PACKAGE=pve-manager
|
||||
PACKAGERELEASE=43
|
||||
PACKAGERELEASE=44
|
||||
|
||||
BINDIR=${DESTDIR}/usr/bin
|
||||
PERLLIBDIR=${DESTDIR}/usr/share/perl5
|
||||
|
Loading…
Reference in New Issue
Block a user