By default, Bugzilla does not search the list of RESOLVED bugs.
You can force it to do so by putting the upper-case word ALL in front of your search query, e.g.: ALL tdelibs
We recommend searching for bugs this way, as you may discover that your bug has already been resolved and fixed in a later release. View | Details | Raw Unified | Return to bug 1623
Collapse All | Expand All

(-)tdelibs/tdecore/tdehw/tderootsystemdevice.cpp (-29 / +29 lines)
Lines 40-54 Link Here
40
	#include <tqdbusconnection.h>
40
	#include <tqdbusconnection.h>
41
#endif // defined(WITH_TDEHWLIB_DAEMONS) || defined(WITH_UPOWER) || defined(WITH_DEVKITPOWER) || defined(WITH_HAL) || defined(WITH_CONSOLEKIT)
41
#endif // defined(WITH_TDEHWLIB_DAEMONS) || defined(WITH_UPOWER) || defined(WITH_DEVKITPOWER) || defined(WITH_HAL) || defined(WITH_CONSOLEKIT)
42
42
43
bool isNetworkFileSystem(TQString fileSystemType) {
43
// bool isNetworkFileSystem(TQString fileSystemType) {
44
	if ((fileSystemType.startsWith("nfs"))
44
// 	if ((fileSystemType.startsWith("nfs"))
45
		|| (fileSystemType == "cifs")
45
// 		|| (fileSystemType == "cifs")
46
		) {
46
// 		) {
47
		return TRUE;
47
// 		return TRUE;
48
	}
48
// 	}
49
49
// 
50
	return FALSE;
50
// 	return FALSE;
51
}
51
// }
52
52
53
TDERootSystemDevice::TDERootSystemDevice(TDEGenericDeviceType::TDEGenericDeviceType dt, TQString dn) : TDEGenericDevice(dt, dn) {
53
TDERootSystemDevice::TDERootSystemDevice(TDEGenericDeviceType::TDEGenericDeviceType dt, TQString dn) : TDEGenericDevice(dt, dn) {
54
	m_hibernationSpace = -1;
54
	m_hibernationSpace = -1;
Lines 126-136 Link Here
126
}
126
}
127
127
128
bool TDERootSystemDevice::canStandby() {
128
bool TDERootSystemDevice::canStandby() {
129
	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
129
// 	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
130
	// See Bug 1615 for details
130
// 	// See Bug 1615 for details
131
	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
131
// 	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
132
		return FALSE;
132
// 		return FALSE;
133
	}
133
// 	}
134
134
135
	TQString statenode = "/sys/power/state";
135
	TQString statenode = "/sys/power/state";
136
	int rval = access (statenode.ascii(), W_OK);
136
	int rval = access (statenode.ascii(), W_OK);
Lines 165-175 Link Here
165
}
165
}
166
166
167
bool TDERootSystemDevice::canFreeze() {
167
bool TDERootSystemDevice::canFreeze() {
168
	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
168
// 	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
169
	// See Bug 1615 for details
169
// 	// See Bug 1615 for details
170
	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
170
// 	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
171
		return FALSE;
171
// 		return FALSE;
172
	}
172
// 	}
173
173
174
	TQString statenode = "/sys/power/state";
174
	TQString statenode = "/sys/power/state";
175
	int rval = access (statenode.ascii(), W_OK);
175
	int rval = access (statenode.ascii(), W_OK);
Lines 204-214 Link Here
204
}
204
}
205
205
206
bool TDERootSystemDevice::canSuspend() {
206
bool TDERootSystemDevice::canSuspend() {
207
	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
207
// 	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
208
	// See Bug 1615 for details
208
// 	// See Bug 1615 for details
209
	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
209
// 	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
210
		return FALSE;
210
// 		return FALSE;
211
	}
211
// 	}
212
212
213
	TQString statenode = "/sys/power/state";
213
	TQString statenode = "/sys/power/state";
214
	int rval = access (statenode.ascii(), W_OK);
214
	int rval = access (statenode.ascii(), W_OK);
Lines 305-315 Link Here
305
}
305
}
306
306
307
bool TDERootSystemDevice::canHibernate() {
307
bool TDERootSystemDevice::canHibernate() {
308
	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
308
// 	// Network file systems mounted on $HOME typically cause nasty suspend/resume failures
309
	// See Bug 1615 for details
309
// 	// See Bug 1615 for details
310
	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
310
// 	if (isNetworkFileSystem(TDEStorageDevice::determineFileSystemType(TDEGlobal::dirs()->localtdedir()))) {
311
		return FALSE;
311
// 		return FALSE;
312
	}
312
// 	}
313
313
314
	TQString statenode = "/sys/power/state";
314
	TQString statenode = "/sys/power/state";
315
	int rval = access (statenode.ascii(), W_OK);
315
	int rval = access (statenode.ascii(), W_OK);

Return to bug 1623