Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 RHEL 5.3 (linux 2.6.18)
我有一个依赖于ftime (3) 返回的时区和 dst 的遗留代码。
现在从ftime (3) 手册页中,我看到不支持时区和dstflag 。在gettimeofday (3) 中也不支持这些字段。
如何检索时区和 dst?
谢谢
您可以使用tzset(3):
tzset(3)
#define _XOPEN_SOURCE #include <time.h> #include <stdio.h> int main(void) { tzset(); printf("%ld, %d\n", timezone, daylight); }
在我的系统上打印“-3600, 1”。
tzsetchar *tzname[2]还使用标准和夏令时时区名称的名称填充数组。
tzset
char *tzname[2]
我正在检查门户页面以加载图像,它的加载速度非常慢。我们从文件系统中选择图像,从数据库中选择图像名称并读取它们,创建一个列表并使用 a4j:mediaOutput 标签显示结果。但是图像的加载速度非常慢。
2 php - 正则表达式不返回适当的匹配