~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/innobase/include/os0file.h

  • Committer: Monty Taylor
  • Date: 2010-12-02 22:51:54 UTC
  • mto: (1975.1.1 build)
  • mto: This revision was merged to the branch mainline in revision 1976.
  • Revision ID: mordred@inaugust.com-20101202225154-h54ifmga9x6cckgs
Refactored syslog module and changed it to use sys_var directly.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/***********************************************************************
2
2
 
3
 
Copyright (C) 1995, 2010, Innobase Oy. All Rights Reserved.
4
 
Copyright (C) 2009, Percona Inc.
 
3
Copyright (c) 1995, 2010, Innobase Oy. All Rights Reserved.
 
4
Copyright (c) 2009, Percona Inc.
5
5
 
6
6
Portions of this file contain modifications contributed and copyrighted
7
7
by Percona Inc.. Those modifications are
177
177
#define OS_WIN95        2       /*!< Microsoft Windows 95 */
178
178
#define OS_WINNT        3       /*!< Microsoft Windows NT 3.x */
179
179
#define OS_WIN2000      4       /*!< Microsoft Windows 2000 */
180
 
#define OS_WINXP        5       /*!< Microsoft Windows XP
181
 
                                or Windows Server 2003 */
182
 
#define OS_WINVISTA     6       /*!< Microsoft Windows Vista
183
 
                                or Windows Server 2008 */
184
 
#define OS_WIN7         7       /*!< Microsoft Windows 7
185
 
                                or Windows Server 2008 R2 */
186
 
 
187
180
 
188
181
extern ulint    os_n_file_reads;
189
182
extern ulint    os_n_file_writes;
201
194
used to register file creation, opening, closing and renaming.
202
195
2) register_pfs_file_io_begin() and register_pfs_file_io_end() are
203
196
used to register actual file read, write and flush */
204
 
# define register_pfs_file_open_begin(state, locker, key, op, name,     \
 
197
# define register_pfs_file_open_begin(locker, key, op, name,            \
205
198
                                      src_file, src_line)               \
206
199
do {                                                                    \
207
200
        if (PSI_server) {                                               \
208
201
                locker = PSI_server->get_thread_file_name_locker(       \
209
 
                        state, key, op, name, &locker);                 \
 
202
                        key, op, name, &locker);                        \
210
203
                if (locker) {                                           \
211
204
                        PSI_server->start_file_open_wait(               \
212
205
                                locker, src_file, src_line);            \
222
215
        }                                                               \
223
216
} while (0)
224
217
 
225
 
# define register_pfs_file_io_begin(state, locker, file, count, op,     \
 
218
# define register_pfs_file_io_begin(locker, file, count, op,            \
226
219
                                    src_file, src_line)                 \
227
220
do {                                                                    \
228
221
        if (PSI_server) {                                               \
229
222
                locker = PSI_server->get_thread_file_descriptor_locker( \
230
 
                        state, file, op);                               \
 
223
                        file, op);                                      \
231
224
                if (locker) {                                           \
232
225
                        PSI_server->start_file_wait(                    \
233
226
                                locker, count, src_file, src_line);     \
375
368
 
376
369
/***********************************************************************//**
377
370
Gets the operating system version. Currently works only on Windows.
378
 
@return OS_WIN95, OS_WIN31, OS_WINNT, OS_WIN2000, OS_WINXP, OS_WINVISTA,
379
 
OS_WIN7. */
 
371
@return OS_WIN95, OS_WIN31, OS_WINNT, or OS_WIN2000 */
380
372
UNIV_INTERN
381
373
ulint
382
374
os_get_os_version(void);
391
383
/***********************************************************************//**
392
384
Creates a temporary file.  This function is like tmpfile(3), but
393
385
the temporary file is created in the MySQL temporary directory.
 
386
On Netware, this function is like tmpfile(3), because the C run-time
 
387
library of Netware does not expose the delete-on-close flag.
394
388
@return temporary file handle, or NULL on error */
395
389
 
396
390
FILE*
1172
1166
        os_file_stat_t* stat_info);     /*!< information of a file in a
1173
1167
                                        directory */
1174
1168
 
1175
 
#if !defined(UNIV_HOTBACKUP)
 
1169
#if !defined(UNIV_HOTBACKUP) && !defined(__NETWARE__)
1176
1170
/*********************************************************************//**
1177
1171
Creates a temporary file that will be deleted on close.
1178
1172
This function is defined in ha_innodb.cc.
1181
1175
int
1182
1176
innobase_mysql_tmpfile(void);
1183
1177
/*========================*/
1184
 
#endif /* !UNIV_HOTBACKUP */
 
1178
#endif /* !UNIV_HOTBACKUP && !__NETWARE__ */
1185
1179
 
1186
1180
 
1187
1181
#if defined(LINUX_NATIVE_AIO)