···11-/*
22- * Copyright (C) 2016 Kevin J. McCarthy <kevin@8t8.us>
33- *
44- * This program is free software; you can redistribute it and/or modify
55- * it under the terms of the GNU General Public License as published by
66- * the Free Software Foundation; either version 2 of the License, or
77- * (at your option) any later version.
88- *
99- * This program is distributed in the hope that it will be useful,
1010- * but WITHOUT ANY WARRANTY; without even the implied warranty of
1111- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1212- * GNU General Public License for more details.
1313- *
1414- * You should have received a copy of the GNU General Public License
1515- * along with this program; if not, write to the Free Software
1616- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1717- */
1818-1919-/* Solaris, OpenIndiana, and probably other derivatives
2020- * are including sys/stream.h inside their sys/socket.h.
2121- *
2222- * This include file is defining macros M_CMD and M_READ which
2323- * are conflicting with the same macros Mutt defines in mutt.h
2424- *
2525- * To minimize breakage with out-of-tree patches, this is a workaround.
2626- */
2727-2828-#ifdef M_CMD
2929-# define MUTT_ORIG_CMD M_CMD
3030-# undef M_CMD
3131-#endif
3232-3333-#ifdef M_READ
3434-# define MUTT_ORIG_READ M_READ
3535-# undef M_READ
3636-#endif
3737-3838-#include <sys/socket.h>
3939-4040-#undef M_CMD
4141-#undef M_READ
4242-4343-#ifdef MUTT_ORIG_CMD
4444-# define M_CMD MUTT_ORIG_CMD
4545-# undef MUTT_ORIG_CMD
4646-#endif
4747-4848-#ifdef MUTT_ORIG_READ
4949-# define M_READ MUTT_ORIG_READ
5050-# undef MUTT_ORIG_READ
5151-#endif