* Major size reduction... over 50% (>1.5k) on i386.
*/
//config:config CAL
-//config: bool "cal"
+//config: bool "cal (6.5 kb)"
//config: default y
//config: help
-//config: cal is used to display a monthly calendar.
+//config: cal is used to display a monthly calendar.
-//applet:IF_CAL(APPLET(cal, BB_DIR_USR_BIN, BB_SUID_DROP))
+//applet:IF_CAL(APPLET_NOEXEC(cal, cal, BB_DIR_USR_BIN, BB_SUID_DROP, cal))
+/* NOEXEC despite rare cases when it can be a "runner" (e.g. cal -n12000 takes you into years 30xx) */
//kbuild:lib-$(CONFIG_CAL) += cal.o
#include "libbb.h"
#include "unicode.h"
-/* We often use "unsigned" intead of "int", it's easier to div on most CPUs */
+/* We often use "unsigned" instead of "int", it's easier to div on most CPUs */
#define THURSDAY 4 /* for reformation */
#define SATURDAY 6 /* 1 Jan 1 was a Saturday */
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ''AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE