conga/ricci/modules/storage GFS1.cpp GFS2.cpp ...
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL5
Changes by: kupcevic at sourceware.org 2007-03-20 16:18:56
Modified files:
ricci/modules/storage: GFS1.cpp GFS2.cpp VG.cpp defines.h
Log message:
storage module: prevent usage of illegal characters for naming
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/GFS1.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.3&r2=1.3.2.1
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/GFS2.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.3.2.1&r2=1.3.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/VG.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.8.2.2&r2=1.8.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/defines.h.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.6&r2=1.6.2.1
ricci/modules/storage/GFS1.cpp +1 -1
@@ -264,7 +264,7 @@ name, 1, 16, - String(" ;!@#$%^& *()+=/\\|?><,.\"':;"), + NAMES_ILLEGAL_CHARS, list<String>()); name_var.set_conditional_bool_if("clustered"); _props.set(name_var);
ricci/modules/storage/GFS2.cpp +1 -1
@@ -252,7 +252,7 @@ name, 1, 16, - String(" ;!@#$%^&*()+=/\\|?><,.\"':;"), + NAMES_ILLEGAL_CHARS, list<String>()); name_var.set_conditional_bool_if("clustered"); _props.set(name_var);
ricci/modules/storage/VG.cpp +6 -4
@@ -28,7 +28,7 @@ #include "defines.h" #include "utils.h" #include "MidAir.h" -#include "LVMClusterLockingError.h"; +#include "LVMClusterLockingError.h" #include "Time.h"
@@ -149,11 +149,13 @@ String lvname = (*iter)->_props.get("lvname").get_string(); lvnames.push_back(lvname); } + lvnames.push_back("_mlog"); + lvnames.push_back("_mimage"); new_lv->props.set(Variable("lvname", String("new_lv"), 1, 36, - "-?/$%!", + NAMES_ILLEGAL_CHARS, lvnames)); new_lv->props.set(Variable("vgname", _vgname));
@@ -168,7 +170,7 @@ String("new_snapshot"), 1, 36, - "-?/$%!", + NAMES_ILLEGAL_CHARS, lvnames)); new_snap->content->_avail_replacements.clear();
@@ -337,7 +339,7 @@ String("new_vg"), 1, 36, - "-?/$%#", + NAMES_ILLEGAL_CHARS, vgnames); props.set(vgname);
ricci/modules/storage/defines.h +3 -1
@@ -1,5 +1,5 @@/* -Copyright Red Hat, Inc. 2005 +Copyright Red Hat, Inc. 2005-2007 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
@@ -100,6 +100,8 @@#define FUNC_RESPONSE_TAG String("function_response") +const static String NAMES_ILLEGAL_CHARS("~`!@#$%^&*()+=[]{}|\\:;\"'<>?"); +#endif // defines_h