~ubuntu-branches/ubuntu/edgy/xfsprogs/edgy

« back to all changes in this revision

Viewing changes to db/xfs_ncheck64.sh

  • Committer: Bazaar Package Importer
  • Author(s): Nathan Scott
  • Date: 2004-07-28 21:11:38 UTC
  • Revision ID: james.westby@ubuntu.com-20040728211138-0v4pdnunnp7na5lm
Tags: 2.6.20-1
* New upstream release.
* Fix xfs_io segfault on non-XFS files.  (closes: #260470)
* Fix packaging botch, deleted files included.  (closes: #260491)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/bin/sh -f
2
2
#
3
 
# Copyright (c) 2000 Silicon Graphics, Inc.  All Rights Reserved.
4
 
 
3
# Copyright (c) 2000-2001 Silicon Graphics, Inc.  All Rights Reserved.
 
4
#
5
5
# This program is free software; you can redistribute it and/or modify it
6
6
# under the terms of version 2 of the GNU General Public License as
7
7
# published by the Free Software Foundation.
8
 
 
8
#
9
9
# This program is distributed in the hope that it would be useful, but
10
10
# WITHOUT ANY WARRANTY; without even the implied warranty of
11
11
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12
 
 
12
#
13
13
# Further, this software is distributed without any warranty that it is
14
14
# free of the rightful claim of any third person regarding infringement
15
15
# or the like.  Any license provided herein, whether implied or
16
16
# otherwise, applies only to this software file.  Patent licenses, if
17
17
# any, provided herein do not apply to combinations of this program with
18
18
# other software, or any other product whatsoever.
19
 
 
19
#
20
20
# You should have received a copy of the GNU General Public License along
21
21
# with this program; if not, write the Free Software Foundation, Inc., 59
22
22
# Temple Place - Suite 330, Boston MA 02111-1307, USA.
23
 
 
23
#
24
24
# Contact information: Silicon Graphics, Inc., 1600 Amphitheatre Pkwy,
25
25
# Mountain View, CA  94043, or:
26
 
27
 
# http://www.sgi.com 
28
 
29
 
# For further information regarding this notice, see: 
30
 
 
26
#
 
27
# http://www.sgi.com
 
28
#
 
29
# For further information regarding this notice, see:
 
30
#
31
31
# http://oss.sgi.com/projects/GenInfo/SGIGPLNoticeExplan/
32
32
#
33
 
#ident "$Revision: 1.1 $"
34
33
 
35
34
OPTS=" "
36
 
ISFILE=" "
37
 
USAGE="usage: xfs_ncheck64 [-sf] [-i ino]... special"
38
 
 
39
 
 
40
 
while getopts "b:fi:sv" c
 
35
DBOPTS=" "
 
36
USAGE="usage: xfs_ncheck64 [-sfvV] [-l logdev] [-i ino]... special"
 
37
 
 
38
while getopts "b:fi:l:svV" c
41
39
do
42
40
        case $c in
43
41
        s)      OPTS=$OPTS"-s ";;
44
42
        i)      OPTS=$OPTS"-i "$OPTARG" ";;
45
 
        f)      ISFILE=" -f";;
 
43
        v)      OPTS=$OPTS"-v ";;
 
44
        V)      OPTS=$OPTS"-V ";;
 
45
        f)      DBOPTS=" -f";;
 
46
        l)      DBOPTS=$DBOPTS" -l "$OPTARG" ";;
46
47
        \?)     echo $USAGE 1>&2
47
48
                exit 2
48
49
                ;;
51
52
set -- extra $@
52
53
shift $OPTIND
53
54
case $# in
54
 
        1)      xfs_db64$ISFILE -r -p xfs_ncheck64 -c "blockget -ns" -c "ncheck$OPTS" $1
 
55
        1)      xfs_db64$DBOPTS -r -p xfs_ncheck64 -c "blockget -ns" -c "ncheck$OPTS" $1
55
56
                status=$?
56
57
                ;;
57
58
        *)      echo $USAGE 1>&2