From c7d5a7e840bf0fe5e3bb126247d5e3e1dcb982bc Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Mon, 13 Mar 2017 10:47:04 +0100 Subject: timespec_to_seconds: Use atomic groups in regex Signed-off-by: Florian Pritz --- lib/App/BorgRestore.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/App') diff --git a/lib/App/BorgRestore.pm b/lib/App/BorgRestore.pm index cf64859..8599f6b 100644 --- a/lib/App/BorgRestore.pm +++ b/lib/App/BorgRestore.pm @@ -155,7 +155,7 @@ sub timespec_to_seconds { my $self = shift; my $timespec = shift; - if ($timespec =~ m/^(?[0-9.]+)(?.+)$/) { + if ($timespec =~ m/^(?>(?[0-9.]+))(?>(?[a-z]+))$/) { my $value = $+{value}; my $unit = $+{unit}; -- cgit v1.2.3-24-g4f1b