Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
halo
external_e2fsprogs
Commits
dec5cd13
Commit
dec5cd13
authored
18 years ago
by
Theodore Ts'o
Browse files
Options
Download
Email Patches
Plain Diff
Fix gcc -Wall complaints in libext2fs
Signed-off-by:
"Theodore Ts'o"
<
tytso@mit.edu
>
parent
2694f319
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
21 additions
and
5 deletions
+21
-5
lib/ext2fs/ChangeLog
lib/ext2fs/ChangeLog
+12
-0
lib/ext2fs/bitops.h
lib/ext2fs/bitops.h
+2
-1
lib/ext2fs/ext2_ext_attr.h
lib/ext2fs/ext2_ext_attr.h
+1
-1
lib/ext2fs/kernel-jbd.h
lib/ext2fs/kernel-jbd.h
+3
-0
lib/ext2fs/namei.c
lib/ext2fs/namei.c
+3
-3
No files found.
lib/ext2fs/ChangeLog
View file @
dec5cd13
2006-11-14 Theodore Tso <tytso@mit.edu>
* namei.c (open_namei): Rename internal variable basename to
base_name to prevent gcc -Wall complaints.
* kernel-jbd.h (tid_gt, tid_geq): Add function declaration to
avoid gcc -Wall complaints.
* ext2_ext_attr.h (EXT2_EXT_ATTR_PAD): Make unsigned to fix gcc
-Wall complaints.
* bitops.h (ext2fs_test_bit): Add missing const to fix gcc -Wall
complaint.
* ext2fs.h (ext2fs_get_mem, ext2fs_free_mem): Avoid type punning
which causes problems on the ARM processor. (Addresses
Debian Bug: #397044)
...
...
This diff is collapsed.
Click to expand it.
lib/ext2fs/bitops.h
View file @
dec5cd13
...
...
@@ -21,6 +21,7 @@ extern void ext2fs_fast_set_bit(unsigned int nr,void * addr);
extern
void
ext2fs_fast_clear_bit
(
unsigned
int
nr
,
void
*
addr
);
extern
__u16
ext2fs_swab16
(
__u16
val
);
extern
__u32
ext2fs_swab32
(
__u32
val
);
extern
__u64
ext2fs_swab64
(
__u64
val
);
#ifdef WORDS_BIGENDIAN
#define ext2fs_cpu_to_le64(x) ext2fs_swab64((x))
...
...
@@ -205,7 +206,7 @@ _INLINE_ int ext2fs_test_bit(unsigned int nr, const void * addr)
{
int
oldbit
;
addr
=
(
void
*
)
(((
unsigned
char
*
)
addr
)
+
(
nr
>>
3
));
addr
=
(
const
void
*
)
(((
const
unsigned
char
*
)
addr
)
+
(
nr
>>
3
));
__asm__
__volatile__
(
"btl %2,%1
\n\t
sbbl %0,%0"
:
"=r"
(
oldbit
)
:
"m"
(
EXT2FS_CONST_ADDR
),
"r"
(
nr
&
7
));
...
...
This diff is collapsed.
Click to expand it.
lib/ext2fs/ext2_ext_attr.h
View file @
dec5cd13
...
...
@@ -36,7 +36,7 @@ struct ext2_ext_attr_entry {
};
#define EXT2_EXT_ATTR_PAD_BITS 2
#define EXT2_EXT_ATTR_PAD (1<<EXT2_EXT_ATTR_PAD_BITS)
#define EXT2_EXT_ATTR_PAD (
(unsigned)
1<<EXT2_EXT_ATTR_PAD_BITS)
#define EXT2_EXT_ATTR_ROUND (EXT2_EXT_ATTR_PAD-1)
#define EXT2_EXT_ATTR_LEN(name_len) \
(((name_len) + EXT2_EXT_ATTR_ROUND + \
...
...
This diff is collapsed.
Click to expand it.
lib/ext2fs/kernel-jbd.h
View file @
dec5cd13
...
...
@@ -794,6 +794,9 @@ extern void journal_brelse_array(struct buffer_head *b[], int n);
extern
void
journal_destroy_revoke
(
journal_t
*
);
#endif
/* __KERNEL__ */
static
inline
int
tid_gt
(
tid_t
x
,
tid_t
y
)
EXT2FS_ATTR
((
unused
));
static
inline
int
tid_geq
(
tid_t
x
,
tid_t
y
)
EXT2FS_ATTR
((
unused
));
/* Comparison functions for transaction IDs: perform comparisons using
* modulo arithmetic so that they work over sequence number wraps. */
...
...
This diff is collapsed.
Click to expand it.
lib/ext2fs/namei.c
View file @
dec5cd13
...
...
@@ -114,7 +114,7 @@ static errcode_t open_namei(ext2_filsys fs, ext2_ino_t root, ext2_ino_t base,
const
char
*
pathname
,
size_t
pathlen
,
int
follow
,
int
link_count
,
char
*
buf
,
ext2_ino_t
*
res_inode
)
{
const
char
*
basename
;
const
char
*
base
_
name
;
int
namelen
;
ext2_ino_t
dir
,
inode
;
errcode_t
retval
;
...
...
@@ -124,13 +124,13 @@ static errcode_t open_namei(ext2_filsys fs, ext2_ino_t root, ext2_ino_t base,
root
,
base
,
pathlen
,
pathname
,
link_count
);
#endif
retval
=
dir_namei
(
fs
,
root
,
base
,
pathname
,
pathlen
,
link_count
,
buf
,
&
basename
,
&
namelen
,
&
dir
);
link_count
,
buf
,
&
base
_
name
,
&
namelen
,
&
dir
);
if
(
retval
)
return
retval
;
if
(
!
namelen
)
{
/* special case: '/usr/' etc */
*
res_inode
=
dir
;
return
0
;
}
retval
=
ext2fs_lookup
(
fs
,
dir
,
basename
,
namelen
,
buf
,
&
inode
);
retval
=
ext2fs_lookup
(
fs
,
dir
,
base
_
name
,
namelen
,
buf
,
&
inode
);
if
(
retval
)
return
retval
;
if
(
follow
)
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment