mirror of
https://github.com/jarun/nnn.git
synced 2025-03-14 10:44:05 +00:00
Fix build break
This commit is contained in:
parent
24b72f65c5
commit
ac2a4041b6
1 changed files with 4 additions and 3 deletions
|
@ -1416,6 +1416,7 @@ static int nextsel(int presel)
|
||||||
uint i;
|
uint i;
|
||||||
const uint len = LEN(bindings);
|
const uint len = LEN(bindings);
|
||||||
#ifdef LINUX_INOTIFY
|
#ifdef LINUX_INOTIFY
|
||||||
|
char *ptr;
|
||||||
struct inotify_event *event;
|
struct inotify_event *event;
|
||||||
static char inotify_buf[EVENT_BUF_LEN]
|
static char inotify_buf[EVENT_BUF_LEN]
|
||||||
__attribute__ ((aligned(__alignof__(struct inotify_event))));
|
__attribute__ ((aligned(__alignof__(struct inotify_event))));
|
||||||
|
@ -1446,9 +1447,9 @@ static int nextsel(int presel)
|
||||||
*/
|
*/
|
||||||
#ifdef LINUX_INOTIFY
|
#ifdef LINUX_INOTIFY
|
||||||
if (!cfg.blkorder && inotify_wd >= 0 && (idle & 1)) {
|
if (!cfg.blkorder && inotify_wd >= 0 && (idle & 1)) {
|
||||||
ssize_t bytes = read(inotify_fd, inotify_buf, EVENT_BUF_LEN);
|
i = read(inotify_fd, inotify_buf, EVENT_BUF_LEN);
|
||||||
if (bytes > 0) {
|
if (i > 0) {
|
||||||
for (char *ptr = inotify_buf; ptr < inotify_buf + bytes;
|
for (ptr = inotify_buf; ptr < inotify_buf + i;
|
||||||
ptr += sizeof(struct inotify_event) + event->len) {
|
ptr += sizeof(struct inotify_event) + event->len) {
|
||||||
event = (struct inotify_event *) ptr;
|
event = (struct inotify_event *) ptr;
|
||||||
DPRINTF_D(event->wd);
|
DPRINTF_D(event->wd);
|
||||||
|
|
Loading…
Add table
Reference in a new issue