summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--PumpKINDlg.cpp7
-rw-r--r--pumpkin.rc5
-rw-r--r--resource.h2
3 files changed, 10 insertions, 4 deletions
diff --git a/PumpKINDlg.cpp b/PumpKINDlg.cpp
index 2a01918..bb15211 100644
--- a/PumpKINDlg.cpp
+++ b/PumpKINDlg.cpp
@@ -780,2 +780,7 @@ CFileException e;
}
+ // XXX: see if we can enforce our preference regarding block size here.
+ if(m_xferSize >= (m_blkSize<<16)) {
+ Deny(tftp::errUndefined,IDS_TFTP_ERROR_TOOBIG);
+ return TRUE;
+ }
state = stateXfer;
@@ -880,3 +885,2 @@ CString msg;
ASSERT(m_Daddy);
-/* // ***
CString tmp;
@@ -884,3 +888,2 @@ CString tmp;
m_Daddy->LogLine(tmp);
- */
tftp* err = tftp::Allocate(tftp::tftpERROR::tftpSize(msg));
diff --git a/pumpkin.rc b/pumpkin.rc
index 5ce2438..adca112 100644
--- a/pumpkin.rc
+++ b/pumpkin.rc
@@ -99,3 +99,3 @@ EXSTYLE WS_EX_ACCEPTFILES | WS_EX_APPWINDOW
CAPTION " PumpKIN"
-FONT 8, "MS Sans Serif"
+FONT 8, "MS Sans Serif", 0, 0, 0x1
BEGIN
@@ -564,3 +564,3 @@ BEGIN
IDS_LOG_XFERSOURCETID "Packet from unexpected source"
- IDS_LOG_SENTTFTPERROR ":%u: %s"
+ IDS_LOG_SENTTFTPERROR ">> %u: %s"
IDS_LOG_GOTTFTPERROR "TFTP:%u: %s"
@@ -658,2 +658,3 @@ BEGIN
IDS_LOG_LOGERROR "Error logging to '%s'"
+ IDS_TFTP_ERROR_TOOBIG "File is too big, try increasing block size"
END
diff --git a/resource.h b/resource.h
index 1bdce59..7961e5e 100644
--- a/resource.h
+++ b/resource.h
@@ -90,2 +90,4 @@
#define IDS_LOG_LOGERROR 161
+#define IDS_TFTP_ERROR_TOOBIG 162
+#define IDS_LOG_DENYING 163
#define IDC_KLEVERNET 1000