Merge branch 'jn/parse-date-basic'
authorJunio C Hamano <gitster@pobox.com>
Fri, 13 Aug 2010 01:31:03 +0000 (18:31 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 13 Aug 2010 01:31:03 +0000 (18:31 -0700)
* jn/parse-date-basic:
Export parse_date_basic() to convert a date string to timestamp

1  2 
cache.h
diff --combined cache.h
index 1e690d1240fb0fb752c0f0660c4c2dff2102e37f,68258be97d84e4d023dccc748c8220b9892bc6cb..37ef9d8a0058bb0cc7826b2a22706064a3f6d3d7
+++ b/cache.h
@@@ -449,7 -449,7 +449,7 @@@ extern int init_db(const char *template
                                alloc = alloc_nr(alloc); \
                        x = xrealloc((x), alloc * sizeof(*(x))); \
                } \
 -      } while(0)
 +      } while (0)
  
  /* Initialize and use the cache information */
  extern int read_index(struct index_state *);
@@@ -811,6 -811,7 +811,7 @@@ const char *show_date_relative(unsigne
                               char *timebuf,
                               size_t timebuf_size);
  int parse_date(const char *date, char *buf, int bufsize);
+ int parse_date_basic(const char *date, unsigned long *timestamp, int *offset);
  void datestamp(char *buf, int bufsize);
  #define approxidate(s) approxidate_careful((s), NULL)
  unsigned long approxidate_careful(const char *, int *);