Merge commit a4db1558bf2b5ca931bd89e4507505a61df06738

Work around a bug in GCC's loop optimization.

Or maybe it's undefined behavior in our C. Or maybe both. Either way,
it wasn't broken before, and now it is. So this fixes it.
This commit is contained in:
Sam Dodrill 2013-09-09 17:23:34 -07:00
parent 2b9892978e
commit 3189f0761b
2 changed files with 66 additions and 1 deletions

View File

@ -0,0 +1,64 @@
/*
* libratbox: a library used by ircd-ratbox and other things
* src/version.c
*
* Copyright (C) 1990 Chelsea Ashley Dyerman
* Copyright (C) 2008 ircd-ratbox development team
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/*
* This file is generated by version.c.SH. Any changes made will go away.
*/
#include "../include/serno.h"
const char *libratbox_generation = "1";
const char *libratbox_platform = "Linux genesect 3.10.10-1-grsec #2-Alpine SMP Mon Sep 2 10:06:15 UTC 2013 x86_64 GNU/Linux";
const char *libratbox_serno = SERIALNUM;
const char *libratbox_creation = "Mon Sep 9 2013 at 15:58:38 PDT";
const char *libratbox_infotext[] =
{
"libratbox --",
"Based on the original code written by Jarkko Oikarinen",
"Copyright 1988, 1989, 1990, 1991 University of Oulu, Computing Center",
"Copyright (c) 1996-2001 Hybrid Development Team",
"Copyright (c) 2002-2008 ircd-ratbox Development Team",
"",
"This program is free software; you can redistribute it and/or",
"modify it under the terms of the GNU General Public License as",
"published by the Free Software Foundation; either version 2, or",
"(at your option) any later version.",
"",
" ",
"ircd-ratbox is an evolution where ircd-hybrid left off around version 7-rc1. ",
"Currently the ircd-ratbox team consists of the following developers:",
" ",
"AndroSyn, Aaron Sethman <androsyn -at- ratbox.org>",
"anfl, Lee Hardy <lee -at- leeh.co.uk>",
"Special thanks for support, code and ideas to:",
"Hwy, W. Campbell <wcampbel -at- botbay.net>",
"jilles, Jilles Tjoelker <jilles -at- stack.nl>",
"larne, Edward Brocklesby <ejb -at- sdf.lonestar.org>",
" ",
"Of course our work is based on the work of many, many others over the past",
"10 or so years since irc has existed, including the work done by the Hybrid",
"team, our thanks goes to them.",
" ",
"",
0,
};

View File

@ -2148,8 +2148,9 @@ set_channel_mode(struct Client *client_p, struct Client *source_p,
add_user_to_channel(chptr, source_p, CHFL_CHANOP);
}
for(j = 0, flags = flags_list[0]; j < 3; j++, flags = flags_list[j])
for(j = 0; j < 3; j++)
{
flags = flags_list[j];
cur_len = mlen;
mbuf = modebuf + mlen;
pbuf = parabuf;