{
rxvt_ptytty **pty = find (ptys.begin (), ptys.end (), cmd.id);
- if (*pty)
+ if (pty)
{
- ptys.erase (pty);
delete *pty;
+ ptys.erase (pty);
}
}
else
sock_fd = sv[1];
for (int fd = 0; fd < 1023; fd++)
- if (fd != sock_fd)
+ if (fd != sock_fd && fd != 1)
close (fd);
serve ();
void erase (iterator first, iterator last)
{
if (last != first) {
- memmove (first, last, (end ()-last)*sizeof (T));
+ memmove (first, last, (end () - last) * sizeof (T));
_last -= last - first;
}
}
void erase (iterator pos)
{
if (pos != end ()) {
- memmove (pos, pos+1, (end ()- (pos+1))*sizeof (T));
+ memmove (pos, pos+1, (end () - (pos+1)) * sizeof (T));
--_last;
}
}