rem: if (flags == 0)
add: if (!(flags & 0xFF))
context: void send_file_entry(struct file_struct *file, int f, unsigned short base_flags){	unsigned short flags;	static time_t modtime;	static mode_t mode;	static DEV64_T rdev;	/* just high bytes in p28 onward */	static DEV64_T dev;	static uid_t uid;	static gid_t gid;	static char lastname[MAXPATHLEN];	char *fname, fbuf[MAXPATHLEN];	int l1, l2;	if (f == -1)		return;	if (!file) {		write_byte(f, 0);		modtime = 0, mode = 0;		rdev = 0, dev = 0;		uid = 0, gid = 0;		*lastname = '\0';		return;	}	io_write_phase = "send_file_entry";	fname = f_name_to(file, fbuf);	flags = base_flags;	if (file->mode == mode)		flags |= XMIT_SAME_MODE;	else		mode = file->mode;	if (preserve_devices) {		if (protocol_version < 28) {			if (IS_DEVICE(mode)) {				if (file->u.rdev == rdev) {					/* Set both flags to simplify the test					 * when writing the data. */					flags |= XMIT_SAME_RDEV_pre28					       | XMIT_SAME_HIGH_RDEV;				} else					rdev = file->u.rdev;			} else				rdev = 0;		} else if (IS_DEVICE(mode)) {			if ((file->u.rdev & ~0xFF) == rdev)				flags |= XMIT_SAME_HIGH_RDEV;			else				rdev = file->u.rdev & ~0xFF;		}	}	if (file->uid == uid)		flags |= XMIT_SAME_UID;	else		uid = file->uid;	if (file->gid == gid)		flags |= XMIT_SAME_GID;	else		gid = file->gid;	if (file->modtime == modtime)		flags |= XMIT_SAME_TIME;	else		modtime = file->modtime;	if (file->link_u.idev) {		if (file->F_DEV == dev) {			if (protocol_version >= 28)				flags |= XMIT_SAME_DEV;		} else			dev = file->F_DEV;		flags |= XMIT_HAS_IDEV_DATA;	}	for (l1 = 0;	     lastname[l1] && (fname[l1] == lastname[l1]) && (l1 < 255);	     l1++) {}	l2 = strlen(fname+l1);	if (l1 > 0)		flags |= XMIT_SAME_NAME;	if (l2 > 255)		flags |= XMIT_LONG_NAME;	/* We must make sure we don't send a zero flags byte or	 * the other end will terminate the flist transfer. */	if (flags == 0 && !S_ISDIR(mode))		flags |= XMIT_TOP_DIR; /* NOTE: no meaning for non-dir */	if (protocol_version >= 28) {		if ((flags & 0xFF00) || flags == 0) {			flags |= XMIT_EXTENDED_FLAGS;			write_byte(f, flags);			write_byte(f, flags >> 8);		} else			write_byte(f, flags);	} else {		if (flags == 0)			flags |= XMIT_LONG_NAME;		write_byte(f, flags);	}	if (flags & XMIT_SAME_NAME)		write_byte(f, l1);	if (flags & XMIT_LONG_NAME)		write_int(f, l2);	else		write_byte(f, l2);	write_buf(f, fname + l1, l2);	write_longint(f, file->length);	if (!(flags & XMIT_SAME_TIME))		write_int(f, modtime);	if (!(flags & XMIT_SAME_MODE))		write_int(f, to_wire_mode(mode));	if (preserve_uid && !(flags & XMIT_SAME_UID)) {		add_uid(uid);		write_int(f, uid);	}	if (preserve_gid && !(flags & XMIT_SAME_GID)) {		add_gid(gid);		write_int(f, gid);	}	if (preserve_devices && IS_DEVICE(mode)) {		/* If XMIT_SAME_HIGH_RDEV is off, XMIT_SAME_RDEV_pre28 is		 * also off.  Also, avoid using "rdev" because it may be		 * incomplete. */		if (!(flags & XMIT_SAME_HIGH_RDEV))			write_int(f, file->u.rdev);		else if (protocol_version >= 28)			write_byte(f, file->u.rdev);	}#if SUPPORT_LINKS	if (preserve_links && S_ISLNK(mode)) {		write_int(f, strlen(file->u.link));		write_buf(f, file->u.link, strlen(file->u.link));	}#endif#if SUPPORT_HARD_LINKS	if (flags & XMIT_HAS_IDEV_DATA) {		if (protocol_version < 26) {			/* 32-bit dev_t and ino_t */			write_int(f, dev);			write_int(f, file->F_INODE);		} else {			/* 64-bit dev_t and ino_t */			if (!(flags & XMIT_SAME_DEV))				write_longint(f, dev);			write_longint(f, file->F_INODE);		}	}#endif	if (always_checksum) {		char *sum;		if (S_ISREG(mode))			sum = file->u.sum;		else if (protocol_version < 28) {			/* Prior to 28, we sent a useless set of nulls. */			sum = empty_sum;		} else			sum = NULL;		if (sum) {			write_buf(f, sum, protocol_version < 21? 2							: MD4_SUM_LENGTH);		}	}	strlcpy(lastname, fname, MAXPATHLEN);	io_write_phase = "unknown";}