refactor unpack, add unpack_from
diff --git a/Lib/struct.py b/Lib/struct.py
index ee5ddc2..648e39c 100644
--- a/Lib/struct.py
+++ b/Lib/struct.py
@@ -73,3 +73,15 @@
     except KeyError:
         o = _compile(fmt)
     return o.unpack(s)
+    
+def unpack_from(fmt, buf, offset=0):
+    """
+    Unpack the buffer, containing packed C structure data, according to
+    fmt starting at offset. Requires len(buffer[offset:]) >= calcsize(fmt).
+    See struct.__doc__ for more on format strings.
+    """
+    try:
+        o = _cache[fmt]
+    except KeyError:
+        o = _compile(fmt)
+    return o.unpack_from(buf, offset)
\ No newline at end of file