Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
b1788c84
Commit
b1788c84
authored
Mar 17, 2007
by
Andrew Talbot
Committed by
Alexandre Julliard
Mar 17, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Replace inline static with static inline.
parent
a33f71a3
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
42 additions
and
42 deletions
+42
-42
fd.c
server/fd.c
+1
-1
file.h
server/file.h
+1
-1
handle.c
server/handle.c
+5
-5
hook.c
server/hook.c
+4
-4
mapping.c
server/mapping.c
+1
-1
process.h
server/process.h
+3
-3
ptrace.c
server/ptrace.c
+1
-1
queue.c
server/queue.c
+10
-10
registry.c
server/registry.c
+1
-1
request.h
server/request.h
+6
-6
sock.c
server/sock.c
+1
-1
thread.c
server/thread.c
+1
-1
trace.c
server/trace.c
+1
-1
user.c
server/user.c
+3
-3
window.c
server/window.c
+2
-2
winstation.c
server/winstation.c
+1
-1
No files found.
server/fd.c
View file @
b1788c84
...
...
@@ -1026,7 +1026,7 @@ static int set_unix_lock( struct fd *fd, file_pos_t start, file_pos_t end, int t
}
/* check if interval [start;end) overlaps the lock */
inline
static
int
lock_overlaps
(
struct
file_lock
*
lock
,
file_pos_t
start
,
file_pos_t
end
)
static
inline
int
lock_overlaps
(
struct
file_lock
*
lock
,
file_pos_t
start
,
file_pos_t
end
)
{
if
(
lock
->
end
&&
start
>=
lock
->
end
)
return
0
;
if
(
end
&&
lock
->
start
>=
end
)
return
0
;
...
...
server/file.h
View file @
b1788c84
...
...
@@ -79,7 +79,7 @@ extern void no_cancel_async( struct fd *fd );
extern
void
main_loop
(
void
);
extern
void
remove_process_locks
(
struct
process
*
process
);
inline
static
struct
fd
*
get_obj_fd
(
struct
object
*
obj
)
{
return
obj
->
ops
->
get_fd
(
obj
);
}
static
inline
struct
fd
*
get_obj_fd
(
struct
object
*
obj
)
{
return
obj
->
ops
->
get_fd
(
obj
);
}
/* timeout functions */
...
...
server/handle.c
View file @
b1788c84
...
...
@@ -69,11 +69,11 @@ static struct handle_table *global_table;
/* handle to table index conversion */
/* handles are a multiple of 4 under NT; handle 0 is not used */
inline
static
obj_handle_t
index_to_handle
(
int
index
)
static
inline
obj_handle_t
index_to_handle
(
int
index
)
{
return
(
obj_handle_t
)((
unsigned
long
)(
index
+
1
)
<<
2
);
}
inline
static
int
handle_to_index
(
obj_handle_t
handle
)
static
inline
int
handle_to_index
(
obj_handle_t
handle
)
{
return
((
unsigned
long
)
handle
>>
2
)
-
1
;
}
...
...
@@ -82,16 +82,16 @@ inline static int handle_to_index( obj_handle_t handle )
#define HANDLE_OBFUSCATOR 0x544a4def
inline
static
int
handle_is_global
(
obj_handle_t
handle
)
static
inline
int
handle_is_global
(
obj_handle_t
handle
)
{
return
((
unsigned
long
)
handle
^
HANDLE_OBFUSCATOR
)
<
0x10000
;
}
inline
static
obj_handle_t
handle_local_to_global
(
obj_handle_t
handle
)
static
inline
obj_handle_t
handle_local_to_global
(
obj_handle_t
handle
)
{
if
(
!
handle
)
return
0
;
return
(
obj_handle_t
)((
unsigned
long
)
handle
^
HANDLE_OBFUSCATOR
);
}
inline
static
obj_handle_t
handle_global_to_local
(
obj_handle_t
handle
)
static
inline
obj_handle_t
handle_global_to_local
(
obj_handle_t
handle
)
{
return
(
obj_handle_t
)((
unsigned
long
)
handle
^
HANDLE_OBFUSCATOR
);
}
...
...
server/hook.c
View file @
b1788c84
...
...
@@ -180,14 +180,14 @@ static struct hook *find_hook( struct thread *thread, int index, void *proc )
}
/* get the first hook in the chain */
inline
static
struct
hook
*
get_first_hook
(
struct
hook_table
*
table
,
int
index
)
static
inline
struct
hook
*
get_first_hook
(
struct
hook_table
*
table
,
int
index
)
{
struct
list
*
elem
=
list_head
(
&
table
->
hooks
[
index
]
);
return
elem
?
HOOK_ENTRY
(
elem
)
:
NULL
;
}
/* check if a given hook should run in the current thread */
inline
static
int
run_hook_in_current_thread
(
struct
hook
*
hook
)
static
inline
int
run_hook_in_current_thread
(
struct
hook
*
hook
)
{
if
((
!
hook
->
process
||
hook
->
process
==
current
->
process
)
&&
(
!
(
hook
->
flags
&
WINEVENT_SKIPOWNPROCESS
)
||
hook
->
process
!=
current
->
process
))
...
...
@@ -200,7 +200,7 @@ inline static int run_hook_in_current_thread( struct hook *hook )
}
/* check if a given hook should run in the owner thread instead of the current thread */
inline
static
int
run_hook_in_owner_thread
(
struct
hook
*
hook
)
static
inline
int
run_hook_in_owner_thread
(
struct
hook
*
hook
)
{
if
((
hook
->
index
==
WH_MOUSE_LL
-
WH_MINHOOK
||
hook
->
index
==
WH_KEYBOARD_LL
-
WH_MINHOOK
))
...
...
@@ -209,7 +209,7 @@ inline static int run_hook_in_owner_thread( struct hook *hook )
}
/* find the first non-deleted hook in the chain */
inline
static
struct
hook
*
get_first_valid_hook
(
struct
hook_table
*
table
,
int
index
,
static
inline
struct
hook
*
get_first_valid_hook
(
struct
hook_table
*
table
,
int
index
,
int
event
,
user_handle_t
win
,
int
object_id
,
int
child_id
)
{
...
...
server/mapping.c
View file @
b1788c84
...
...
@@ -266,7 +266,7 @@ static int get_image_params( struct mapping *mapping )
}
/* get the size of the unix file associated with the mapping */
inline
static
int
get_file_size
(
struct
file
*
file
,
file_pos_t
*
size
)
static
inline
int
get_file_size
(
struct
file
*
file
,
file_pos_t
*
size
)
{
struct
stat
st
;
int
unix_fd
=
get_file_unix_fd
(
file
);
...
...
server/process.h
View file @
b1788c84
...
...
@@ -145,14 +145,14 @@ extern void finish_process_tracing( struct process *process );
extern
int
read_process_memory
(
struct
process
*
process
,
const
void
*
ptr
,
data_size_t
size
,
char
*
dest
);
extern
int
write_process_memory
(
struct
process
*
process
,
void
*
ptr
,
data_size_t
size
,
const
char
*
src
);
inline
static
process_id_t
get_process_id
(
struct
process
*
process
)
{
return
process
->
id
;
}
static
inline
process_id_t
get_process_id
(
struct
process
*
process
)
{
return
process
->
id
;
}
inline
static
int
is_process_init_done
(
struct
process
*
process
)
static
inline
int
is_process_init_done
(
struct
process
*
process
)
{
return
process
->
startup_state
==
STARTUP_DONE
;
}
inline
static
struct
process_dll
*
get_process_exe_module
(
struct
process
*
process
)
static
inline
struct
process_dll
*
get_process_exe_module
(
struct
process
*
process
)
{
struct
list
*
ptr
=
list_head
(
&
process
->
dlls
);
return
ptr
?
LIST_ENTRY
(
ptr
,
struct
process_dll
,
entry
)
:
NULL
;
...
...
server/ptrace.c
View file @
b1788c84
...
...
@@ -86,7 +86,7 @@
#define PT_READ_D 3
#define PT_WRITE_D 4
#define PT_STEP 5
inline
static
int
ptrace
(
int
req
,
...)
{
errno
=
EPERM
;
return
-
1
;
/*FAIL*/
}
static
inline
int
ptrace
(
int
req
,
...)
{
errno
=
EPERM
;
return
-
1
;
/*FAIL*/
}
#endif
/* HAVE_SYS_PTRACE_H */
/* handle a status returned by wait4 */
...
...
server/queue.c
View file @
b1788c84
...
...
@@ -306,13 +306,13 @@ void set_queue_hooks( struct thread *thread, struct hook_table *hooks )
}
/* check the queue status */
inline
static
int
is_signaled
(
struct
msg_queue
*
queue
)
static
inline
int
is_signaled
(
struct
msg_queue
*
queue
)
{
return
((
queue
->
wake_bits
&
queue
->
wake_mask
)
||
(
queue
->
changed_bits
&
queue
->
changed_mask
));
}
/* set some queue bits */
inline
static
void
set_queue_bits
(
struct
msg_queue
*
queue
,
unsigned
int
bits
)
static
inline
void
set_queue_bits
(
struct
msg_queue
*
queue
,
unsigned
int
bits
)
{
queue
->
wake_bits
|=
bits
;
queue
->
changed_bits
|=
bits
;
...
...
@@ -320,26 +320,26 @@ inline static void set_queue_bits( struct msg_queue *queue, unsigned int bits )
}
/* clear some queue bits */
inline
static
void
clear_queue_bits
(
struct
msg_queue
*
queue
,
unsigned
int
bits
)
static
inline
void
clear_queue_bits
(
struct
msg_queue
*
queue
,
unsigned
int
bits
)
{
queue
->
wake_bits
&=
~
bits
;
queue
->
changed_bits
&=
~
bits
;
}
/* check whether msg is a keyboard message */
inline
static
int
is_keyboard_msg
(
struct
message
*
msg
)
static
inline
int
is_keyboard_msg
(
struct
message
*
msg
)
{
return
(
msg
->
msg
>=
WM_KEYFIRST
&&
msg
->
msg
<=
WM_KEYLAST
);
}
/* check if message is matched by the filter */
inline
static
int
check_msg_filter
(
unsigned
int
msg
,
unsigned
int
first
,
unsigned
int
last
)
static
inline
int
check_msg_filter
(
unsigned
int
msg
,
unsigned
int
first
,
unsigned
int
last
)
{
return
(
msg
>=
first
&&
msg
<=
last
);
}
/* check whether a message filter contains at least one potential hardware message */
inline
static
int
filter_contains_hw_range
(
unsigned
int
first
,
unsigned
int
last
)
static
inline
int
filter_contains_hw_range
(
unsigned
int
first
,
unsigned
int
last
)
{
/* hardware message ranges are (in numerical order):
* WM_NCMOUSEFIRST .. WM_NCMOUSELAST
...
...
@@ -354,7 +354,7 @@ inline static int filter_contains_hw_range( unsigned int first, unsigned int las
}
/* get the QS_* bit corresponding to a given hardware message */
inline
static
int
get_hardware_msg_bit
(
struct
message
*
msg
)
static
inline
int
get_hardware_msg_bit
(
struct
message
*
msg
)
{
if
(
msg
->
msg
==
WM_MOUSEMOVE
||
msg
->
msg
==
WM_NCMOUSEMOVE
)
return
QS_MOUSEMOVE
;
if
(
is_keyboard_msg
(
msg
))
return
QS_KEY
;
...
...
@@ -362,7 +362,7 @@ inline static int get_hardware_msg_bit( struct message *msg )
}
/* get the current thread queue, creating it if needed */
inline
static
struct
msg_queue
*
get_current_queue
(
void
)
static
inline
struct
msg_queue
*
get_current_queue
(
void
)
{
struct
msg_queue
*
queue
=
current
->
queue
;
if
(
!
queue
)
queue
=
create_msg_queue
(
current
,
NULL
);
...
...
@@ -370,7 +370,7 @@ inline static struct msg_queue *get_current_queue(void)
}
/* get a (pseudo-)unique id to tag hardware messages */
inline
static
unsigned
int
get_unique_id
(
void
)
static
inline
unsigned
int
get_unique_id
(
void
)
{
static
unsigned
int
id
;
if
(
!++
id
)
id
=
1
;
/* avoid an id of 0 */
...
...
@@ -860,7 +860,7 @@ static void thread_input_destroy( struct object *obj )
}
/* fix the thread input data when a window is destroyed */
inline
static
void
thread_input_cleanup_window
(
struct
msg_queue
*
queue
,
user_handle_t
window
)
static
inline
void
thread_input_cleanup_window
(
struct
msg_queue
*
queue
,
user_handle_t
window
)
{
struct
thread_input
*
input
=
queue
->
input
;
...
...
server/registry.c
View file @
b1788c84
...
...
@@ -350,7 +350,7 @@ static void key_destroy( struct object *obj )
}
/* get the request vararg as registry path */
inline
static
void
get_req_path
(
struct
unicode_str
*
str
,
int
skip_root
)
static
inline
void
get_req_path
(
struct
unicode_str
*
str
,
int
skip_root
)
{
static
const
WCHAR
root_name
[]
=
{
'\\'
,
'R'
,
'e'
,
'g'
,
'i'
,
's'
,
't'
,
'r'
,
'y'
,
'\\'
};
...
...
server/request.h
View file @
b1788c84
...
...
@@ -66,32 +66,32 @@ extern void trace_request(void);
extern
void
trace_reply
(
enum
request
req
,
const
union
generic_reply
*
reply
);
/* get the request vararg data */
inline
static
const
void
*
get_req_data
(
void
)
static
inline
const
void
*
get_req_data
(
void
)
{
return
current
->
req_data
;
}
/* get the request vararg size */
inline
static
data_size_t
get_req_data_size
(
void
)
static
inline
data_size_t
get_req_data_size
(
void
)
{
return
current
->
req
.
request_header
.
request_size
;
}
/* get the request vararg as unicode string */
inline
static
void
get_req_unicode_str
(
struct
unicode_str
*
str
)
static
inline
void
get_req_unicode_str
(
struct
unicode_str
*
str
)
{
str
->
str
=
get_req_data
();
str
->
len
=
(
get_req_data_size
()
/
sizeof
(
WCHAR
))
*
sizeof
(
WCHAR
);
}
/* get the reply maximum vararg size */
inline
static
data_size_t
get_reply_max_size
(
void
)
static
inline
data_size_t
get_reply_max_size
(
void
)
{
return
current
->
req
.
request_header
.
reply_size
;
}
/* allocate and fill the reply data */
inline
static
void
*
set_reply_data
(
const
void
*
data
,
data_size_t
size
)
static
inline
void
*
set_reply_data
(
const
void
*
data
,
data_size_t
size
)
{
void
*
ret
=
set_reply_data_size
(
size
);
if
(
ret
)
memcpy
(
ret
,
data
,
size
);
...
...
@@ -99,7 +99,7 @@ inline static void *set_reply_data( const void *data, data_size_t size )
}
/* set the reply data pointer directly (will be freed by request code) */
inline
static
void
set_reply_data_ptr
(
void
*
data
,
data_size_t
size
)
static
inline
void
set_reply_data_ptr
(
void
*
data
,
data_size_t
size
)
{
assert
(
size
<=
get_reply_max_size
()
);
current
->
reply_size
=
size
;
...
...
server/sock.c
View file @
b1788c84
...
...
@@ -284,7 +284,7 @@ static void sock_wake_up( struct sock *sock, int pollev )
}
}
inline
static
int
sock_error
(
struct
fd
*
fd
)
static
inline
int
sock_error
(
struct
fd
*
fd
)
{
unsigned
int
optval
=
0
,
optlen
;
...
...
server/thread.c
View file @
b1788c84
...
...
@@ -136,7 +136,7 @@ static const struct fd_ops thread_fd_ops =
static
struct
list
thread_list
=
LIST_INIT
(
thread_list
);
/* initialize the structure for a newly allocated thread */
inline
static
void
init_thread_structure
(
struct
thread
*
thread
)
static
inline
void
init_thread_structure
(
struct
thread
*
thread
)
{
int
i
;
...
...
server/trace.c
View file @
b1788c84
...
...
@@ -47,7 +47,7 @@ static const char *get_status_name( unsigned int status );
/* utility functions */
inline
static
void
remove_data
(
data_size_t
size
)
static
inline
void
remove_data
(
data_size_t
size
)
{
cur_data
=
(
const
char
*
)
cur_data
+
size
;
cur_size
-=
size
;
...
...
server/user.c
View file @
b1788c84
...
...
@@ -45,13 +45,13 @@ static struct user_handle *handle_to_entry( user_handle_t handle )
return
NULL
;
}
inline
static
user_handle_t
entry_to_handle
(
struct
user_handle
*
ptr
)
static
inline
user_handle_t
entry_to_handle
(
struct
user_handle
*
ptr
)
{
int
index
=
ptr
-
handles
;
return
(
user_handle_t
)((((
unsigned
long
)
index
<<
1
)
+
FIRST_USER_HANDLE
)
+
(
ptr
->
generation
<<
16
));
}
inline
static
struct
user_handle
*
alloc_user_entry
(
void
)
static
inline
struct
user_handle
*
alloc_user_entry
(
void
)
{
struct
user_handle
*
handle
;
...
...
@@ -78,7 +78,7 @@ inline static struct user_handle *alloc_user_entry(void)
return
handle
;
}
inline
static
void
*
free_user_entry
(
struct
user_handle
*
ptr
)
static
inline
void
*
free_user_entry
(
struct
user_handle
*
ptr
)
{
void
*
ret
;
ret
=
ptr
->
ptr
;
...
...
server/window.c
View file @
b1788c84
...
...
@@ -107,7 +107,7 @@ static struct window *progman_window;
static
struct
window
*
taskman_window
;
/* retrieve a pointer to a window from its handle */
inline
static
struct
window
*
get_window
(
user_handle_t
handle
)
static
inline
struct
window
*
get_window
(
user_handle_t
handle
)
{
struct
window
*
ret
=
get_user_object
(
handle
,
USER_WINDOW
);
if
(
!
ret
)
set_win32_error
(
ERROR_INVALID_WINDOW_HANDLE
);
...
...
@@ -285,7 +285,7 @@ static obj_handle_t get_property( struct window *win, atom_t atom )
}
/* destroy all properties of a window */
inline
static
void
destroy_properties
(
struct
window
*
win
)
static
inline
void
destroy_properties
(
struct
window
*
win
)
{
int
i
;
...
...
server/winstation.c
View file @
b1788c84
...
...
@@ -186,7 +186,7 @@ static WCHAR *build_desktop_name( const struct unicode_str *name,
}
/* retrieve a pointer to a desktop object */
inline
static
struct
desktop
*
get_desktop_obj
(
struct
process
*
process
,
obj_handle_t
handle
,
static
inline
struct
desktop
*
get_desktop_obj
(
struct
process
*
process
,
obj_handle_t
handle
,
unsigned
int
access
)
{
return
(
struct
desktop
*
)
get_handle_obj
(
process
,
handle
,
access
,
&
desktop_ops
);
...
...
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