/* Extended regular expression matching and search library.
Copyright (C) 2002, 2003 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Isamu Hasegawa <isamu@yamato.ibm.com>.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, write to the Free
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
static reg_errcode_t match_ctx_init (re_match_context_t *cache, int eflags,
re_string_t *input, int n);
static void match_ctx_clean (re_match_context_t *mctx);
static void match_ctx_free (re_match_context_t *cache);
static void match_ctx_free_subtops (re_match_context_t *mctx);
static reg_errcode_t match_ctx_add_entry (re_match_context_t *cache, int node,
int str_idx, int from, int to);
static int search_cur_bkref_entry (re_match_context_t *mctx, int str_idx);
static void match_ctx_clear_flag (re_match_context_t *mctx);
static reg_errcode_t match_ctx_add_subtop (re_match_context_t *mctx, int node,
int str_idx);
static re_sub_match_last_t * match_ctx_add_sublast (re_sub_match_top_t *subtop,
int node, int str_idx);
static void sift_ctx_init (re_sift_context_t *sctx, re_dfastate_t **sifted_sts,
re_dfastate_t **limited_sts, int last_node,
int last_str_idx, int check_subexp);
static reg_errcode_t re_search_internal (const regex_t *preg,
const char *string, int length,
int start, int range, int stop,
size_t nmatch, regmatch_t pmatch[],
int eflags);
static int re_search_2_stub (struct re_pattern_buffer *bufp,
const char *string1, int length1,
const char *string2, int length2,
int start, int range, struct re_registers *regs,
int stop, int ret_len);
static int re_search_stub (struct re_pattern_buffer *bufp,
const char *string, int length, int start,
int range, int stop, struct re_registers *regs,
int ret_len);
static unsigned re_copy_regs (struct re_registers *regs, regmatch_t *pmatch,
int nregs, int regs_allocated);
static inline re_dfastate_t *acquire_init_state_context (reg_errcode_t *err,
const regex_t *preg,
const re_match_context_t *mctx,
int idx);
static reg_errcode_t prune_impossible_nodes (const regex_t *preg,
re_match_context_t *mctx);
static int check_matching (const regex_t *preg, re_match_context_t *mctx,
int fl_search, int fl_longest_match);
static int check_halt_node_context (const re_dfa_t *dfa, int node,
unsigned int context);
static int check_halt_state_context (const regex_t *preg,
const re_dfastate_t *state,
const re_match_context_t *mctx, int idx);
static void update_regs (re_dfa_t *dfa, regmatch_t *pmatch, int cur_node,
int cur_idx, int nmatch);
static int proceed_next_node (const regex_t *preg, int nregs, regmatch_t *regs,
const re_match_context_t *mctx,
int *pidx, int node, re_node_set *eps_via_nodes,
struct re_fail_stack_t *fs);
static reg_errcode_t push_fail_stack (struct re_fail_stack_t *fs,
int str_idx, int *dests, int nregs,
regmatch_t *regs,
re_node_set *eps_via_nodes);
static int pop_fail_stack (struct re_fail_stack_t *fs, int *pidx, int nregs,
regmatch_t *regs, re_node_set *eps_via_nodes);
static reg_errcode_t set_regs (const regex_t *preg,
const re_match_context_t *mctx,
size_t nmatch, regmatch_t *pmatch,
int fl_backtrack);
static reg_errcode_t free_fail_stack_return (struct re_fail_stack_t *fs);
#ifdef RE_ENABLE_I18N
static int sift_states_iter_mb (const regex_t *preg,
const re_match_context_t *mctx,
re_sift_context_t *sctx,
int node_idx, int str_idx, int max_str_idx);
#endif /* RE_ENABLE_I18N */
static reg_errcode_t sift_states_backward (const regex_t *preg,
re_match_context_t *mctx,
re_sift_context_t *sctx);
static reg_errcode_t update_cur_sifted_state (const regex_t *preg,
re_match_context_t *mctx,
re_sift_context_t *sctx,
int str_idx,
re_node_set *dest_nodes);
static reg_errcode_t add_epsilon_src_nodes (re_dfa_t *dfa,
re_node_set *dest_nodes,
const re_node_set *candidates);
static reg_errcode_t sub_epsilon_src_nodes (re_dfa_t *dfa, int node,
re_node_set *dest_nodes,
const re_node_set *and_nodes);
static int check_dst_limits (re_dfa_t *dfa, re_node_set *limits,
re_match_context_t *mctx, int dst_node,
int dst_idx, int src_node, int src_idx);
static int check_dst_limits_calc_pos (re_dfa_t *dfa, re_match_context_t *mctx,
int limit, re_node_set *eclosures,
int subexp_idx, int node, int str_idx);
static reg_errcode_t check_subexp_limits (re_dfa_t *dfa,
re_node_set *dest_nodes,
const re_node_set *candidates,
re_node_set *limits,
struct re_backref_cache_entry *bkref_ents,
int str_idx);
static reg_errcode_t sift_states_bkref (const regex_t *preg,
re_match_context_t *mctx,
re_sift_context_t *sctx,
int str_idx, re_node_set *dest_nodes);
static reg_errcode_t clean_state_log_if_need (re_match_context_t *mctx,
int next_state_log_idx);
static reg_errcode_t merge_state_array (re_dfa_t *dfa, re_dfastate_t **dst,
re_dfastate_t **src, int num);
static re_dfastate_t *transit_state (reg_errcode_t *err, const regex_t *preg,
re_match_context_t *mctx,
re_dfastate_t *state, int fl_search);
static reg_errcode_t check_subexp_matching_top (re_dfa_t *dfa,
re_match_context_t *mctx,
re_node_set *cur_nodes,
int str_idx);
static re_dfastate_t *transit_state_sb (reg_errcode_t *err, const regex_t *preg,
re_dfastate_t *pstate,
int fl_search,
re_match_context_t *mctx);
#ifdef RE_ENABLE_I18N
static reg_errcode_t transit_state_mb (const regex_t *preg,
re_dfastate_t *pstate,
re_match_context_t *mctx);
#endif /* RE_ENABLE_I18N */
static reg_errcode_t transit_state_bkref (const regex_t *preg,
re_node_set *nodes,
re_match_context_t *mctx);
static reg_errcode_t get_subexp (const regex_t *preg, re_match_context_t *mctx,
int bkref_node, int bkref_str_idx);
static reg_errcode_t get_subexp_sub (const regex_t *preg,
re_match_context_t *mctx,
re_sub_match_top_t *sub_top,
re_sub_match_last_t *sub_last,
int bkref_node, int bkref_str);
static int find_subexp_node (re_dfa_t *dfa, re_node_set *nodes,
int subexp_idx, int fl_open);
static reg_errcode_t check_arrival (const regex_t *preg,
re_match_context_t *mctx,
state_array_t *path, int top_node,
int top_str, int last_node, int last_str,
int fl_open);
static reg_errcode_t check_arrival_add_next_nodes (const regex_t *preg,
re_dfa_t *dfa,
re_match_context_t *mctx,
int str_idx,
re_node_set *cur_nodes,
re_node_set *next_nodes);
static reg_errcode_t check_arrival_expand_ecl (re_dfa_t *dfa,
re_node_set *cur_nodes,
int ex_subexp, int fl_open);
static reg_errcode_t check_arrival_expand_ecl_sub (re_dfa_t *dfa,
re_node_set *dst_nodes,
int target, int ex_subexp,
int fl_open);
static reg_errcode_t expand_bkref_cache (const regex_t *preg,
re_match_context_t *mctx,
re_node_set *cur_nodes, int cur_str,
int last_str,
没有合适的资源?快使用搜索试试~ 我知道了~
smartmontools-5.41
4星 · 超过85%的资源 需积分: 9 9 下载量 56 浏览量
2011-07-05
22:54:22
上传
评论
收藏 723KB GZ 举报
温馨提示
共106个文件
h:32个
cpp:27个
in:11个
SMART(SFF-8035i) 是硬盘生产商们建立的一个工业标准,这个标准就是在硬盘上保存一个跟执行情况,可靠程度,读找错误率等属性的表格。所有属性都有一个1byte(大小范围 1-253)的标准化值,还包含另一个1byte的关键阶段值,如果属性表格内某个数据接近小于或达到关键阶段值,那么你的硬盘就快跟你永别了,至少也是超过它的设计使用极限了- 该做备份和最坏的打算了
资源推荐
资源详情
资源评论
收起资源包目录
smartmontools-5.41 (106个子文件)
Makefile.am 24KB
AUTHORS 2KB
regexec.c 117KB
regcomp.c 98KB
getopt.c 34KB
regex_internal.c 34KB
getopt1.c 5KB
syslogevt.c 4KB
regex.c 3KB
CHANGELOG 170KB
smartd.conf 7KB
configure 234KB
COPYING 18KB
smartd.cpp 157KB
os_win32.cpp 123KB
os_linux.cpp 102KB
atacmds.cpp 96KB
ataprint.cpp 90KB
scsicmds.cpp 86KB
scsiprint.cpp 58KB
os_freebsd.cpp 51KB
scsiata.cpp 44KB
smartctl.cpp 39KB
daemon_win32.cpp 32KB
knowndrives.cpp 25KB
os_qnxnto.cpp 24KB
utility.cpp 23KB
atacmdnames.cpp 14KB
os_darwin.cpp 14KB
os_solaris.cpp 14KB
os_openbsd.cpp 13KB
os_netbsd.cpp 13KB
syslog_win32.cpp 10KB
os_generic.cpp 9KB
dev_legacy.cpp 9KB
dev_interface.cpp 9KB
cciss.cpp 7KB
wmiquery.cpp 5KB
hostname_win32.cpp 5KB
dev_ata_cmd_set.cpp 3KB
depcomp 18KB
Example1 2KB
Example2 722B
Example3 693B
Example4 126B
config.guess 44KB
drivedb.h 68KB
csmisas.h 55KB
atacmds.h 34KB
dev_interface.h 24KB
os_qnxnto.h 23KB
regex.h 21KB
regex_internal.h 21KB
os_freebsd.h 17KB
scsicmds.h 16KB
os_linux.h 11KB
utility.h 10KB
wbemcli_small.h 8KB
getopt.h 6KB
megaraid.h 5KB
wmiquery.h 4KB
ataprint.h 4KB
smartctl.h 3KB
knowndrives.h 3KB
int64.h 3KB
scsiprint.h 2KB
dev_tunnelled.h 2KB
os_solaris.h 2KB
daemon_win32.h 2KB
os_openbsd.h 2KB
syslog.h 2KB
os_netbsd.h 2KB
os_generic.h 1KB
dev_ata_cmd_set.h 1KB
atacmdnames.h 1KB
os_darwin.h 1KB
hostname_win32.h 958B
cciss.h 236B
Makefile.in 86KB
smartctl.8.in 82KB
smartd.8.in 81KB
smartd.conf.5.in 56KB
configure.in 20KB
smartd.initd.in 18KB
config.h.in 5KB
update-smart-drivedb.in 3KB
smartd.freebsd.initd.in 1KB
SMART.in 1KB
smartd.service.in 248B
INSTALL 31KB
install-sh 13KB
aclocal.m4 42KB
syslogevt.mc 3KB
missing 11KB
NEWS 18KB
installer.nsi 28KB
update-smart-drivedb.nsi 4KB
StartupParameters.plist 116B
README 4KB
README 2KB
共 106 条
- 1
- 2
资源评论
- 24K金2013-01-29谢谢分享,不太好用
aazz156
- 粉丝: 5
- 资源: 8
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功