Skip to content

Commit fbab3ff

Browse files
committed
SD Fixes
1 parent 4b022f2 commit fbab3ff

File tree

4 files changed

+13
-19
lines changed

4 files changed

+13
-19
lines changed

i18n/SageTVCoreTranslations.properties

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,6 @@ DISKSPACE_INADEQUATE_ERR_MSG=Your system is out of diskspace for recording TV. S
449449
SYSTEM_LOCKUP_DETECTION=System Lockup Detected
450450
OUT_OF_MEMORY=Out of Memory Detected
451451
OUT_OF_MEMORY_MSG=SageTV has detected that it has run out of memory. You may need to increase your JVM heap size or there could be a plugin/customization that is causing an issue.
452-
SOFTWARE_UPDATE_AVAILABLE=Software Updates Available
453452
PLUGIN_UPDATE_AVAILABLE_MSG=There is an update available of the plugin "{0}" to version {1}.
454453
STORAGE_MONITOR=Storage Monitor
455454
STORAGE_MONITOR_MSG=A degraded state has been detected for the RAID device "{0}" due to a hard disk failure. Please use the server Administrator console from your web browser to diagnose and resolve the problem.
@@ -485,8 +484,8 @@ LINEUP_SD_ACCOUNT_LOCKOUT=Schedules Direct Account Locked
485484
LINEUP_SD_ACCOUNT_LOCKOUT_MSG=The Schedules Direct account is locked. There have been too many login failures. The account will unlock again in 15 minutes.
486485
LINEUP_SD_ACCOUNT_BLOCKED=Schedules Direct Account Blocked
487486
LINEUP_SD_ACCOUNT_BLOCKED_MSG=The Schedules Direct account is blocked. Please contact Schedules Direct to resolve this issue.
488-
SOFTWARE_UPDATE_AVAILABLE_MSG=Software update available
489-
SOFTWARE_UPDATE_AVAILABLE=New version available on Github: "{0}". Go to: "{1}" to check it out.
487+
SOFTWARE_UPDATE_AVAILABLE=Software update available
488+
SOFTWARE_UPDATE_AVAILABLE_MSG=New version available on Github: "{0}". Go to: "{1}" to check it out.
490489
Team=Team
491490
Guest_Voice=Guest Voice
492491
Anchor=Anchor

java/sage/SageConstants.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@ private SageConstants()
2222
// Non-instantiable
2323
}
2424

25-
public static final int BUILD_VERSION = 1046;
25+
public static final int BUILD_VERSION = 1037;
2626
}

java/sage/epg/sd/SDRipper.java

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@
9191
import static sage.epg.sd.SDErrors.SAGETV_UNKNOWN;
9292
import static sage.epg.sd.SDErrors.SERVICE_OFFLINE;
9393
import static sage.epg.sd.SDErrors.TOO_MANY_LOGINS;
94+
import static sage.epg.sd.SDSession.debugEnabled;
9495

9596
public class SDRipper extends EPGDataSource
9697
{
@@ -227,7 +228,7 @@ private static SDSession openNewSession() throws IOException, SDException
227228
{
228229
SDSession returnValue = null;
229230
BufferedReader reader = null;
230-
231+
231232
//2025-02-28 jusjoken: switch to using sage properties for user/pass so it can be shared with clients that need it
232233
String propUsername = null;
233234
String propPassword = null;
@@ -242,7 +243,6 @@ private static SDSession openNewSession() throws IOException, SDException
242243
propUsername = serverProp.toString();
243244
serverProp = SageTV.api("GetServerProperty", new Object[] { PROP_PASSWORD, null });
244245
propPassword = serverProp.toString();
245-
//if (Sage.DBG) System.out.println("***EPG*** getting from CLIENT user/pass: username:" + username + " password:" + password);
246246
}
247247
catch (Throwable t)
248248
{
@@ -256,10 +256,7 @@ private static SDSession openNewSession() throws IOException, SDException
256256
propPassword = Sage.get(PROP_PASSWORD, null);
257257
}
258258

259-
//if (Sage.DBG) System.out.println("***EPG*** checking for user/pass: username:" + username + " password:" + password);
260-
261259
//get user/pass from old sdauth file
262-
//if (Sage.DBG) System.out.println("***EPG*** reading user/pass from old file");
263260
File authFile = new File(AUTH_FILE);
264261
if (!authFile.exists() || authFile.length() == 0)
265262
throw new SDException(SDErrors.SAGETV_NO_PASSWORD);
@@ -307,9 +304,8 @@ private static SDSession openNewSession() throws IOException, SDException
307304
// This will throw an exception if there are any issues connecting.
308305
returnValue = new SDSageSession(propUsername, propPassword);
309306
authenticated = true;
310-
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Authenticated using prop based user/pass PASSED: username:" + propUsername + " password:" + propPassword);
311307
} catch (Exception e) {
312-
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Checking for prop based user/pass FAILED: username:" + propUsername + " password:" + propPassword);
308+
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Checking for prop based user/pass FAILED");
313309
}
314310
}
315311

@@ -321,9 +317,8 @@ private static SDSession openNewSession() throws IOException, SDException
321317
authenticated = true;
322318
Sage.put(PROP_USERNAME, fileUsername);
323319
Sage.put(PROP_PASSWORD, filePassword);
324-
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Authenticated using file based user/pass PASSED: username:" + fileUsername + " password:" + filePassword);
325320
} catch (Exception e) {
326-
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Checking for file based user/pass FAILED: username:" + fileUsername + " password:" + filePassword);
321+
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Checking for file based user/pass FAILED");
327322
}
328323
}
329324

@@ -336,7 +331,7 @@ private static SDSession openNewSession() throws IOException, SDException
336331
// We have just successfully authenticated, so this needs to be cleared so that updates can
337332
// start immediately.
338333
SDRipper.retryWait = 0;
339-
if (Sage.DBG) System.out.println("SDRipper:openNewSession: Successfully got token: " + returnValue.token);
334+
if (Sage.DBG&& debugEnabled()) System.out.println("SDRipper:openNewSession: Successfully got token: " + returnValue.token);
340335
return returnValue;
341336
}
342337

java/sage/msg/SystemMessage.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,11 @@ public class SystemMessage extends SageMsg
6161
// General
6262
public static final int SYSTEM_LOCKUP_DETECTION_MSG = 1200;
6363
public static final int OUT_OF_MEMORY_MSG = 1201;
64-
public static final int SOFTWARE_UPDATE_AVAILABLE_MSG = 1202;
64+
public static final int PLUGIN_UPDATE_AVAILABLE_MSG = 1202;
6565
public static final int STORAGE_MONITOR_MSG = 1203;
6666
public static final int GENERAL_MSG = 1204;
6767
public static final int PLUGIN_INSTALL_MISSING_FILE_MSG = 1205;
68+
public static final int SOFTWARE_UPDATE_AVAILABLE_MSG = 1206;
6869

6970
public static String getNameForMsgType(int msgType)
7071
{
@@ -117,7 +118,7 @@ public static String getNameForMsgType(int msgType)
117118
case RECORDING_BITRATE_TOO_LOW_ERROR_MSG:
118119
return sage.Sage.rez("RECORDING_BITRATE_TOO_LOW_ERROR");
119120
case SOFTWARE_UPDATE_AVAILABLE_MSG:
120-
return sage.Sage.rez("SOFTWARE_UPDATE_AVAILABLE");
121+
return sage.Sage.rez("SOFTWARE_UPDATE_AVAILABLE_MSG");
121122
case STORAGE_MONITOR_MSG:
122123
return sage.Sage.rez("STORAGE_MONITOR");
123124
case CAPTURE_DEVICE_DATASCAN_ERROR_MSG:
@@ -199,9 +200,8 @@ public static SystemMessage createVersionUpdateMsg(String version, String locati
199200
java.util.Properties props = new java.util.Properties();
200201
props.setProperty("Version", version);
201202
props.setProperty("Location", location);
202-
String versionMsg = "New version on github: " + version + " go to:" + location;
203203
return new SystemMessage(SOFTWARE_UPDATE_AVAILABLE_MSG, INFO_PRIORITY,
204-
sage.Sage.rez("SOFTWARE_UPDATE_AVAILABLE", new Object[] { version, location }), props);
204+
sage.Sage.rez("SOFTWARE_UPDATE_AVAILABLE_MSG", new Object[] { version, location }), props);
205205
}
206206

207207
public static SystemMessage createPluginUpdateMsg(String pluginID, String pluginName, String version)
@@ -211,7 +211,7 @@ public static SystemMessage createPluginUpdateMsg(String pluginID, String plugin
211211
props.setProperty("PluginName", pluginName);
212212
props.setProperty("Version", version);
213213
props.setProperty("IsPluginUpdate", "true");
214-
return new SystemMessage(SOFTWARE_UPDATE_AVAILABLE_MSG, INFO_PRIORITY,
214+
return new SystemMessage(PLUGIN_UPDATE_AVAILABLE_MSG, INFO_PRIORITY,
215215
sage.Sage.rez("PLUGIN_UPDATE_AVAILABLE_MSG", new Object[] { pluginName, version }), props);
216216
}
217217

0 commit comments

Comments
 (0)