all repos — fluxbox @ d2aad76c13694bd417e74bfee064cfdc8875f9a2

custom fork of the fluxbox windowmanager

fixed checking on valid key or modifier, bug [ 600811 ]
fluxgen fluxgen
commit

d2aad76c13694bd417e74bfee064cfdc8875f9a2

parent

40825bf4e105bd3fba43e3061bb63a28e702ca68

1 files changed, 7 insertions(+), 2 deletions(-)

jump to
M src/Keys.ccsrc/Keys.cc

@@ -19,7 +19,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -//$Id: Keys.cc,v 1.18 2002/08/11 21:21:06 fluxgen Exp $ +//$Id: Keys.cc,v 1.19 2002/08/28 20:25:15 fluxgen Exp $ #include "Keys.hh"

@@ -221,8 +221,13 @@ //keyarg=0;

int tmpmod=getModifier(val[argc].c_str()); if(tmpmod) mod|=tmpmod; //If it's a modifier - else{ + else { key = getKey(val[argc].c_str()); // else get the key + if (key == 0) { + cerr<<"["<<filename<<"]: Invalid key/modifier on line("<< + line<<"): "<<linebuffer<<endl; + break; // get next line + } if (!current_key) { current_key = new t_key(key, mod); last_key = current_key;