tztime: fix argument parsing bug, clarify docs
authorPhil Sutter <phil@nwl.cc>
Sun, 4 Oct 2009 01:59:47 +0000 (03:59 +0200)
committerPhil Sutter <phil@nwl.cc>
Sun, 4 Oct 2009 02:03:21 +0000 (04:03 +0200)
doc/variables.xml
src/timeinfo.c

index 3472c78..40e9907 100644 (file)
             <command>
                 <option>tztime</option>
             </command>
-            <option>(timezone) (format)</option>
+            <option>(timezone (format))</option>
         </term>
         <listitem>Local time for specified timezone, see man
         strftime to get more information about format. The timezone
index 0a88fe8..0812d73 100644 (file)
@@ -46,9 +46,9 @@ void scan_tztime(struct text_object *obj, const char *arg)
 
                switch (nArgs) {
                        case 2:
-                               tz = buf1;
-                       case 1:
                                fmt = buf2;
+                       case 1:
+                               tz = buf1;
                }
        }