Bug 137105 - sysutils/freebsd-snapshot not handling non C LANG/LC_ALL
Summary: sysutils/freebsd-snapshot not handling non C LANG/LC_ALL
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-24 22:10 UTC by Guy Brand
Modified: 2009-09-17 22:30 UTC (History)
0 users

See Also:


Attachments
file.shar (7.90 KB, text/plain)
2009-07-24 22:10 UTC, Guy Brand
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Guy Brand 2009-07-24 22:10:07 UTC
snapshot (from sysutils/freebsd-snapshot) doesn't handle properly LANG/LC_ALL settings and included awk calculations on filesystems (and snapshots) fail.

Fix: A simple fix is to force LANG/LC_ALL to C:

# LC_ALL=C snapshot list /var       
Filesystem          User   User%     Snap   Snap%  Snapshot       
/var               845MB    3.1%      3MB    0.0%  daily.1        
/var               845MB    3.1%      2MB    0.0%  daily.0        
/var               845MB    3.1%    762KB    0.0%  hourly.3       
/var               845MB    3.1%    520KB    0.0%  hourly.2       
/var               845MB    3.1%    388KB    0.0%  hourly.1       
/var               845MB    3.1%    372KB    0.0%  hourly.0       

Updated port attached.

Patch attached with submission follows:
How-To-Repeat: # LC_ALL=fr_FR.ISO8859-15 snapshot list /var
Filesystem          User   User%     Snap   Snap%  Snapshot       
/usr/local/sbin/snapshot: arith: syntax error: "3,17 * 1024"
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2009-07-24 22:10:16 UTC
Maintainer of sysutils/freebsd-snapshot,

Please note that PR ports/137105 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/137105

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2009-07-24 22:10:18 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 3 Graham Todd 2009-07-26 20:28:58 UTC
Edwin Groothuis wrote:
> Maintainer of sysutils/freebsd-snapshot,
> 
> Please note that PR ports/137105 has just been submitted.
> 
> If it contains a patch for an upgrade, an enhancement or a bug fix
> you agree on, reply to this email stating that you approve the patch
> and a committer will take care of it.
> 
> The full text of the PR can be found at:
>     http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/137105
> 

I approve.  The updated port includes fairly simple change and solves a
relatively straightforward problem. Changes have been added to the patch
file against upstream source.

./files/patch-snapshot now includes:

X+LC_ALL=C
X+LANG=C
Comment 4 Mark Linimon freebsd_committer freebsd_triage 2009-07-26 21:35:45 UTC
State Changed
From-To: feedback->open

Maintainer approved.
Comment 5 Pav Lucistnik freebsd_committer freebsd_triage 2009-09-17 22:21:21 UTC
State Changed
From-To: open->closed

Committed, thanks!
Comment 6 dfilter service freebsd_committer freebsd_triage 2009-09-17 22:26:23 UTC
pav         2009-09-17 21:26:15 UTC

  FreeBSD ports repository

  Modified files:
    sysutils/freebsd-snapshot Makefile 
    sysutils/freebsd-snapshot/files patch-snapshot 
  Log:
  - Run script under C locale
  
  PR:             ports/137105
  Submitted by:   Guy Brand <gb@unistra.fr>
  Approved by:    Graham Todd <gtodd@bellanet.org> (maintainer)
  Feature safe:   yes
  
  Revision  Changes    Path
  1.9       +1 -0      ports/sysutils/freebsd-snapshot/Makefile
  1.3       +3 -1      ports/sysutils/freebsd-snapshot/files/patch-snapshot
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"