fix 2 bus errors on osx:
- it's std::string doesnt like being set to NULL. - in Window.cc, caught someone using a membr variable after calling 'delete this'. bad.
This commit is contained in:
parent
1b129560d0
commit
5067369f76
2 changed files with 8 additions and 4 deletions
|
@ -1402,8 +1402,13 @@ void BScreen::removeWorkspaceNames(void) {
|
|||
void BScreen::LoadStyle(void) {
|
||||
Resource &conf = resource.styleconfig;
|
||||
|
||||
conf.setFile(openbox.getStyleFilename());
|
||||
if (!conf.load()) {
|
||||
const char *sfile = openbox.getStyleFilename();
|
||||
bool loaded = false;
|
||||
if (sfile != NULL) {
|
||||
conf.setFile(sfile);
|
||||
loaded = conf.load();
|
||||
}
|
||||
if (!loaded) {
|
||||
conf.setFile(DEFAULTSTYLE);
|
||||
if (!conf.load()) {
|
||||
fprintf(stderr, i18n->getMessage(ScreenSet, ScreenDefaultStyleLoadFail,
|
||||
|
|
|
@ -168,9 +168,8 @@ OpenboxWindow::OpenboxWindow(Openbox &o, Window w, BScreen *s) : openbox(o) {
|
|||
#ifdef SLIT
|
||||
if (client.initial_state == WithdrawnState) {
|
||||
screen->getSlit()->addClient(client.window);
|
||||
delete this;
|
||||
|
||||
openbox.ungrab();
|
||||
delete this;
|
||||
return;
|
||||
}
|
||||
#endif // SLIT
|
||||
|
|
Loading…
Reference in a new issue