エントリーの編集
![loading...](https://b.st-hatena.com/bdefb8944296a0957e54cebcfefc25c4dcff9f5f/images/v4/public/common/loading@2x.gif)
エントリーの編集は全ユーザーに共通の機能です。
必ずガイドラインを一読の上ご利用ください。
革命の日々! 効率的なdirectry readingコードについて
記事へのコメント0件
- 注目コメント
- 新着コメント
このエントリーにコメントしてみましょう。
注目コメント算出アルゴリズムの一部にLINEヤフー株式会社の「建設的コメント順位付けモデルAPI」を使用しています
![アプリのスクリーンショット](https://b.st-hatena.com/bdefb8944296a0957e54cebcfefc25c4dcff9f5f/images/v4/public/entry/app-screenshot.png)
- バナー広告なし
- ミュート機能あり
- ダークモード搭載
関連記事
革命の日々! 効率的なdirectry readingコードについて
Ulrich Drepper が自身のブログで、効率的なディレクトリ読み込みについてエントリを書いている。 しか... Ulrich Drepper が自身のブログで、効率的なディレクトリ読み込みについてエントリを書いている。 しかし、改善案が思いっきり linux+glibc 依存なのでこれを実践できる人は少ないだろうな。と苦笑 元記事: http://udrepper.livejournal.com/18555.html 以下、抜粋 ダメなコード DIR *dir = opendir(some_path); struct dirent *d; struct dirent d_mem; while (readdir_r(d, &d_mem, &d) == 0) { char path[PATH_MAX]; snprintf(path, sizeof(path), "%s/%s/somefile", some_path, d->d_name); int fd = open(path, O_RDONLY);