summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmdkapplet-enterprise-update-helper11
-rwxr-xr-xmdkapplet-restricted-helper12
-rw-r--r--mdkonline.pm14
3 files changed, 14 insertions, 23 deletions
diff --git a/mdkapplet-enterprise-update-helper b/mdkapplet-enterprise-update-helper
index d6d0754a..5c0c85e0 100755
--- a/mdkapplet-enterprise-update-helper
+++ b/mdkapplet-enterprise-update-helper
@@ -101,17 +101,6 @@ sub get_restricted_authentication() {
}
}
-sub get_from {
- my ($link, $header) = @_;
-
- my $ua = LWP::UserAgent->new;
- $ua->agent("mdkapplet (mdkonline-$mdkonline::version)");
- $ua->env_proxy;
-
- my $response = $ua->request(POST $link, $header);
- $response;
-}
-
sub has_mes5_rights {
my ($ref) = @_;
$ref->{data}{groups}{'es5-prod'} || $ref->{data}{groups}{'es5-demo'};
diff --git a/mdkapplet-restricted-helper b/mdkapplet-restricted-helper
index 18aefdb1..e3e19b63 100755
--- a/mdkapplet-restricted-helper
+++ b/mdkapplet-restricted-helper
@@ -107,18 +107,6 @@ sub get_restricted_authentication() {
}
}
-sub get_from {
- my ($link, $header) = @_;
-
- my $ua = LWP::UserAgent->new;
- $ua->agent(sprintf('mdkapplet (mdkonline-%s; distribution: %s)',
- $mdkonline::version, $version));
- $ua->env_proxy;
-
- my $response = $ua->request(POST $link, $header);
- $response;
-}
-
my $error;
sub add_restricted_medium {
my ($email, $password) = @_;
diff --git a/mdkonline.pm b/mdkonline.pm
index 7175355e..5ae5cd76 100644
--- a/mdkonline.pm
+++ b/mdkonline.pm
@@ -32,6 +32,7 @@ use ugtk2;
our @ISA = qw(Exporter);
our @EXPORT = qw(fork_exec
get_banner
+ get_from
get_product_id
get_stale_upgrade_filename
is_enterprise_media_supported
@@ -115,6 +116,19 @@ sub is_running {
$found;
}
+
+sub get_from {
+ my ($link, $header) = @_;
+
+ my $ua = LWP::UserAgent->new;
+ $ua->agent(sprintf('mdkapplet (mdkonline-%s; distribution: %s)',
+ $mdkonline::version, $version));
+ $ua->env_proxy;
+
+ my $response = $ua->request(POST $link, $header);
+ $response;
+}
+
# callers need to require XML::Simple
sub xml2perl {
my ($res) = @_;